For Programmers: Free Programming Magazines  


Home > Archive > Java Help > January 2007 > Problem with texture of UI









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Problem with texture of UI
stacey

2007-01-22, 8:20 am

Hello everyone,

I have the following problem.
I am making a java application, and i have several call to Matlab
functions.
Maybe you dont know it, but in Matlab 7.3 there is a java compiler so
you can make java code out of Matlab code.

When i call those functions, the texture of the buttons and everything
messes up. It dissapears!
E.g. The buttons before the call have a sort of texture.., after the
call , ther are just simple square shapes, like if you take a pencil
and draw them yourselves.

This happens in jRadioButtons as well, and in pop up messages. In pop
up messages the letter lose their boldness..
I can print screen them if you want.

I haven't got any clue why this is happening.
I haven't touched the look&Feel.

Any suggestions/ideas??

Thank you very much.

Stavroula

Larry Barowski

2007-01-22, 8:20 am


"stacey" <staceyventuras@gmail.com> wrote in message
news:1169376628.234870.129030@11g2000cwr.googlegroups.com...
> Hello everyone,
>
> I have the following problem.
> I am making a java application, and i have several call to Matlab
> functions.
> Maybe you dont know it, but in Matlab 7.3 there is a java compiler so
> you can make java code out of Matlab code.
>
> When i call those functions, the texture of the buttons and everything
> messes up. It dissapears!
> E.g. The buttons before the call have a sort of texture.., after the
> call , ther are just simple square shapes, like if you take a pencil
> and draw them yourselves.
>
> This happens in jRadioButtons as well, and in pop up messages. In pop
> up messages the letter lose their boldness..
> I can print screen them if you want.
>
> I haven't got any clue why this is happening.
> I haven't touched the look&Feel.
>
> Any suggestions/ideas??


For a start, you could print out UIManager.getLookAndFeel() to
see if the Matlab code is changing it. I would suspect that some
static initializer is setting a "Matlab Look & Feel".


stacey

2007-01-22, 7:08 pm



All the buttons are updated apart from the letters in pop ups, as
mentioned above.

What do you mean " What interface am i using to access Matlab from
Java??"

I am doing the following procedure:
1) I write a function in matlab code and i use the matlab javabuilder
to compile it and make it into a java package wich contains this
function, with a specific API.
2) Then insert the package into my java application and i create an
instance of the class and i call its method which is the function i
wrote. if i want to pass numeric arguments, i have to declare them in
type: MWNumericArray.
Thats it. actually.

I dont use any L&F coommands.. as far as i know. I dont know what
matlab does, i have no tutorial for Java builder. I have asked in
matlab groups, but havent got any answer.

Thank you again,

Stavroula







On Jan 21, 11:08 pm, "Larry Barowski"
<MElarrybar-AT-eng_DOT_auburnANOTHERDOTeduEND> wrote:
> "stacey" <staceyventu...@gmail.com> wrote in messagenews:1169395652.457945.4780@38g2000cwa.googlegroups.com...
>
>
> visible is not that simple. You have to update all
> of the UI, which could be easy or difficult
> depending on your application. Anyway, you
> certainly don't want to be resetting the L&F
> after every Matlab call. What interface are you
> using to access Matlab from Java? Are there any
> L&F specific commands?


Larry Barowski

2007-01-23, 7:30 pm


"stacey" <staceyventuras@gmail.com> wrote in message
news:1169497524.929560.138280@q2g2000cwa.googlegroups.com...
> I am doing the following procedure:
> 1) I write a function in matlab code and i use the matlab javabuilder
> to compile it and make it into a java package wich contains this
> function, with a specific API.
> 2) Then insert the package into my java application and i create an
> instance of the class and i call its method which is the function i
> wrote. if i want to pass numeric arguments, i have to declare them in
> type: MWNumericArray.
> Thats it. actually.
>
> I dont use any L&F coommands.. as far as i know. I dont know what
> matlab does, i have no tutorial for Java builder. I have asked in
> matlab groups, but havent got any answer.


I can't find anything about Look&Feel in their online docs.
Since it seems they are using the system L&F, you could
just call a Matlab method before you create any interface
and stick with that, until you find a better solution. At least
that way you won't have components with different L&Fs
mixed up in your application.


Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com