com.vlsolutions.swing.toolbars
Class VLToolBarLayout
java.lang.Object
com.vlsolutions.swing.toolbars.VLToolBarLayout
- LayoutManager2
public class VLToolBarLayout
extends java.lang.Object
implements LayoutManager2
The layout for VLToolBar (supports horizontal and vertical orientation).
When used in horizontal orientation, this layout respects the preferred width of
the contained components, and forces the height to the maximum of all the preferred heights.
(so components are vertically streched to have the same height).
When used in vertical orientation, this layout respects the preferred height of
the contained components, and forces the width to the maximum of all the preferred widths.
(so components are horizontally streched to have the same width).
VLToolBarLayout
public VLToolBarLayout()
VLToolBarLayout
public VLToolBarLayout(boolean isHorizontal)
Constructs a new Layout.
isHorizontal
- indicates if the layout will be horizontal or vertical.
VLToolBarLayout
public VLToolBarLayout(boolean isHorizontal,
int gap)
Constructs a new Layout.
isHorizontal
- indicates if the layout will be horizontal or vertical.gap
- gap in pixels between components
addLayoutComponent
public void addLayoutComponent(Component comp,
Object constraints)
addLayoutComponent
public void addLayoutComponent(String name,
Component comp)
getLayoutAlignmentX
public float getLayoutAlignmentX(Container target)
getLayoutAlignmentY
public float getLayoutAlignmentY(Container target)
invalidateLayout
public void invalidateLayout(Container target)
layoutContainer
public void layoutContainer(Container target)
overridden to adjust position (x(top) = width(left), y(left) = height(top)
maximumLayoutSize
public Dimension maximumLayoutSize(Container target)
minimumLayoutSize
public Dimension minimumLayoutSize(Container parent)
preferredLayoutSize
public Dimension preferredLayoutSize(Container parent)
removeLayoutComponent
public void removeLayoutComponent(Component comp)
© Copyright 2004-2006 VLSolutions. All Rights Reserved.
www.vlsolutions.com : Java Components - Smart Client Applications