JideBoxLayout and Vertical Alignment

This is the forum for JIDE Common Layer which is open sourced at https://github.com/jidesoft/jide-oss. Please note, JIDE technical support doesn't monitor this forum as often as other forums. Please consider subscribe for technical support for JIDE Common Layer so that you can use customer only forum to get a timely response.

Moderator: JIDE Support

Forum rules
Community driven forum for open source JIDE Common Layer. JIDE technical support doesn't monitor this forum as often as other forums. If you only use JIDE Common Layer, please consider subscribing for technical support for JIDE Common Layer so that you can use customer only forum to get a timely response.

JideBoxLayout and Vertical Alignment

Postby tolask » Wed Nov 07, 2007 1:04 pm

Dear All,

I have the following problem.
I add 3 components to an horizontal JideBoxLayout. The first component has the vertical alignment set to TOP... but it's still center-aligned in the panel...
Anybody can confirm this ?

Thomas
tolask
 
Posts: 37
Joined: Fri Jul 13, 2007 7:55 am

Postby JIDE Support » Wed Nov 07, 2007 3:54 pm

I tried in JideBoxLayoutDemo by setting

button.setVerticalAlignment(SwingConstants.TOP)

to the buttons in that demo. It seems aligned on top correctly. Maybe you try to replace it with BoxLayout just to verify if it is JideBoxLayout problem, or see if you reproduce it in JideBoxLayoutDemo.

Thanks,
JIDE Software Technical Support Team
JIDE Support
Site Admin
 
Posts: 37219
Joined: Sun Sep 14, 2003 10:49 am

Postby tolask » Wed Nov 07, 2007 4:33 pm

You are absolutely right. If I use setVerticalAlignment() it works like a charm.
Actually, I used setAlignmentX() which is available in JComponent (setVerticalAlignment is not, it's only available for some subclasses).
Perhaps the JideBoxLayout should have a look in this property as well.

My 2 cents,

Thomas
tolask
 
Posts: 37
Joined: Fri Jul 13, 2007 7:55 am

Postby JIDE Support » Wed Nov 07, 2007 4:36 pm

JideBoxLayout should have nothing to do either properties. Does your code work with BoxLayout?

Thanks,
JIDE Software Technical Support Team
JIDE Support
Site Admin
 
Posts: 37219
Joined: Sun Sep 14, 2003 10:49 am


Return to JIDE Common Layer Open Source Project Discussion (Community Driven)

Who is online

Users browsing this forum: No registered users and 68 guests