The Artima Developer Community
Sponsored Link

Legacy Java Answers Forum
September 2000



This page contains an archived post to the Java Answers Forum made prior to February 25, 2002. If you wish to participate in discussions, please visit the new Artima Forums.


JToolBar Layout affected by Box.Filler

Posted by Gerard Peregrin on September 27, 2000 at 3:54 PM

Have you noticed that the HORIZONTAL Distance between the JTooBar Component Bar and the components added to the JToolBar is automatically adjusted by the Dimension Variables that can be set by your Dimension Methods (getMaximumSize, getMinimumSize, and getPreferredSize via a return statement) for a Box.Filler component even when the JToolBar BoxLayout is set to VERTICALLY arrange the JToolBar components? This means that your components will arranged vertically as expected but their HORIZONTAL position gets altered by the integer values specified in your dimension properties for the Box.Filler spacing component. It may not be a bug, then again it may be. It certainly isn't intuitive for a VERTICAL spacer to affect the HORIZONTAL position of the components. You can adjust the horizontal positioning of the components, if you have added a Box.Filler spacer, by using the Filler's dimension properties to establish the desired horizontal distance between the Bar and the Components. Working for The International Law Channel. Out of Site - InCite. :o)


Sponsored Links

Copyright © 1996-2009 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use - Advertise with Us