Basic usage problem

I'm finally trying to design a serious form, and I'm running into a very basic problem using BorderLayout.

I start with the base panel using a BorderLayout. To this I add JPanel jp1 in the WEST, with its own BorderLayout.

Problem is, jp1 displays with zero-width, which does not make a good drop zone for components to be added to it. I can add by dragging to jp1 in the tree view instead, but there's no way to specify, either during the drag/drop or afterwards, what the constraints should be on the component.

Any ideas?

3 comments

Hello Peris,

Just for a reference: this is the issue http://www.jetbrains.net/jira/browse/IDEADEV-9313.

I'm finally trying to design a serious form, and I'm running into a
very basic problem using BorderLayout.

I start with the base panel using a BorderLayout. To this I add JPanel
jp1 in the WEST, with its own BorderLayout.

Problem is, jp1 displays with zero-width, which does not make a good
drop zone for components to be added to it. I can add by dragging to
jp1 in the tree view instead, but there's no way to specify, either
during the drag/drop or afterwards, what the constraints should be on
the component.

Any ideas?

Alexander.


0

The workaround mentioned there by Dimitry doesn't quite work unless you can control the component's BorderLayout position constraint, during or after the insertion. Is this possible?

0

Hello Peris,

The workaround mentioned there by Dimitry doesn't quite work unless
you can control the component's BorderLayout position constraint,
during or after the insertion. Is this possible?


Recent Selena EAP builds allow you to change the BorderLayout constraint
of a component through the properties pane.

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


0

Please sign in to leave a comment.