JLayeredPane support in UI Designer

I am using the UI Designer in IDEA 7.0.1. I noticed there is no pre-configured component in the palette for JLayeredPane. I added one to the palette with support for "isContainer". I was also able to use this component in my form and I was able to add my own components to this JLayeredPane in my form. But, it appears that under the covers, the GUI builder only calls the generic version of the add method like this
layeredPane.add(myComponent);

instead of the version needed by JLayeredPane to specify the layer number like this:
layeredPane.add(myComponent, new Integer(i));

Is there any way for the UI builder to call the add() method with a constraints object?
Is there any way to get around this?

4 comments

I guess the deafening silence answers my question...

0

Is there any way to get around this?


You could try to use a client property. (I've not tried it)

If you look at the source of JLayeredPane, you see that it supports
a "layeredContainerLayer" client property (type Integer).
Set this client property at the child components of the layered pane.

An alternative would be to use JFormDesigner ;) (www.formdev.com)

0

Well, I just decided that the IDEA GUI designer is just overkill for I was needing to do. I just coded the form by hand.

0

Hello Gary,

I am using the UI Designer in IDEA 7.0.1. I noticed there is no
pre-configured component in the palette for JLayeredPane. I added one
to the palette with support for "isContainer". I was also able to use
this component in my form and I was able to add my own components to
this JLayeredPane in my form. But, it appears that under the covers,
the GUI builder only calls the generic version of the add method like
this
layeredPane.add(myComponent);
instead of the version needed by JLayeredPane to specify the layer
number like this:
layeredPane.add(myComponent, new Integer(i));
Is there any way for the UI builder to call the add() method with a
constraints object? Is there any way to get around this?


There's currently no specific support for JLayeredPane in the UI designer.
We'll investigate the possibility of adding it in the next version.

--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"


0

Please sign in to leave a comment.