public class KopiMultiBlockLayout
extends java.lang.Object
implements org.kopi.galite.visual.form.LayoutManager
| Constructor and Description |
|---|
KopiMultiBlockLayout(int col,
int line) |
| Modifier and Type | Method and Description |
|---|---|
void |
addLayoutComponent(java.awt.Component comp,
java.lang.Object constraints)
Adds the specified component to the layout, using the specified
constraint object.
|
void |
addLayoutComponent(java.lang.String name,
java.awt.Component comp)
Deprecated.
replaced by
addLayoutComponent(Component, Object). |
int |
getColumnPos(int x)
get Column Pos, returns the pos of a column
|
int |
getHgap()
Returns the horizontal gap between components.
|
float |
getLayoutAlignmentX(java.awt.Container parent)
Returns the alignment along the x axis.
|
float |
getLayoutAlignmentY(java.awt.Container parent)
Returns the alignment along the y axis.
|
int |
getVgap()
Returns the vertical gap between components.
|
void |
invalidateLayout(java.awt.Container target)
Invalidates the layout, indicating that if the layout manager
has cached information it should be discarded.
|
void |
layoutContainer(java.awt.Container target)
Lays out the container argument using this border layout.
|
java.awt.Dimension |
maximumLayoutSize(java.awt.Container target)
Returns the maximum dimensions for this layout given the components
in the specified target container.
|
java.awt.Dimension |
minimumLayoutSize(java.awt.Container target)
Determines the minimum size of the
target container
using this layout manager. |
java.awt.Dimension |
preferredLayoutSize(java.awt.Container target)
Determines the preferred size of the
target
container using this layout manager, based on the components
in the container. |
void |
removeLayoutComponent(java.awt.Component comp)
Removes the specified component from this border layout.
|
void |
setHgap(int hgap)
Sets the horizontal gap between components.
|
void |
setVgap(int vgap)
Sets the vertical gap between components.
|
java.lang.String |
toString()
Returns a string representation of the state of this border layout.
|
public KopiMultiBlockLayout(int col,
int line)
col - number of columnsline - number of linespublic int getHgap()
public void setHgap(int hgap)
hgap - the horizontal gap between componentspublic int getVgap()
public void setVgap(int vgap)
vgap - the vertical gap between componentspublic void addLayoutComponent(java.awt.Component comp,
java.lang.Object constraints)
addLayoutComponent in interface java.awt.LayoutManager2comp - the component to be added.constraints - an object that specifies how and wherepublic void addLayoutComponent(java.lang.String name,
java.awt.Component comp)
addLayoutComponent(Component, Object).addLayoutComponent in interface java.awt.LayoutManagerpublic void removeLayoutComponent(java.awt.Component comp)
remove or
removeAll methods. Most applications do not call this
method directly.removeLayoutComponent in interface java.awt.LayoutManagercomp - the component to be removed.Container.remove(Component),
Container.removeAll()public java.awt.Dimension minimumLayoutSize(java.awt.Container target)
target container
using this layout manager.
This method is called when a container calls its
getMinimumSize method. Most applications do not call
this method directly.
minimumLayoutSize in interface java.awt.LayoutManagertarget - the container in which to do the layout.Container,
BorderLayout.preferredLayoutSize(java.awt.Container),
Container.getMinimumSize()public int getColumnPos(int x)
public java.awt.Dimension preferredLayoutSize(java.awt.Container target)
target
container using this layout manager, based on the components
in the container.
Most applications do not call this method directly. This method
is called when a container calls its getPreferredSize
method.
preferredLayoutSize in interface java.awt.LayoutManagertarget - the container in which to do the layout.Container,
BorderLayout.minimumLayoutSize(java.awt.Container),
Container.getPreferredSize()public java.awt.Dimension maximumLayoutSize(java.awt.Container target)
maximumLayoutSize in interface java.awt.LayoutManager2target - the component which needs to be laid outContainer,
minimumLayoutSize(java.awt.Container),
preferredLayoutSize(java.awt.Container)public float getLayoutAlignmentX(java.awt.Container parent)
getLayoutAlignmentX in interface java.awt.LayoutManager2public float getLayoutAlignmentY(java.awt.Container parent)
getLayoutAlignmentY in interface java.awt.LayoutManager2public void invalidateLayout(java.awt.Container target)
invalidateLayout in interface java.awt.LayoutManager2public void layoutContainer(java.awt.Container target)
This method actually reshapes the components in the specified
container in order to satisfy the constraints of this
BorderLayout object. The North
and Southcomponents, if any, are placed at
the top and bottom of the container, respectively. The
West and East components are
then placed on the left and right, respectively. Finally,
the Center object is placed in any remaining
space in the middle.
Most applications do not call this method directly. This method
is called when a container calls its doLayout method.
layoutContainer in interface java.awt.LayoutManagertarget - the container in which to do the layout.Container,
Container.doLayout()public java.lang.String toString()
toString in class java.lang.Object