|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--dog.gui.VerticalFlowLayout
A vertical flow layout is used to lay out components in a panel. It will arrange the components from top to bottom until no more components fit in the same column. The columns can be aligned vertically.
| Field Summary | |
static int |
BOTTOM
The bottom alignment variable. |
static int |
CENTER
The centre alignment variable. |
static int |
TOP
The top alignment variable. |
| Constructor Summary | |
VerticalFlowLayout()
Constructs a new layout with a centered alignment and a default 5-unit horizontal and vertical gap. |
|
VerticalFlowLayout(int align)
Constructs a new layout with the specified alignment and a default 5-unit horizontal and vertical gap. |
|
VerticalFlowLayout(int align,
int hgap,
int vgap)
Constructs a new layout with the specified alignment and gap values. |
|
VerticalFlowLayout(int align,
int hgap,
int vgap,
boolean maximise)
Constructs a new layout with the specified alignment and gap values. |
|
| Method Summary | |
void |
addLayoutComponent(java.lang.String name,
java.awt.Component comp)
Adds the specified component to the layout. |
int |
getAlignment()
Returns the alignment value for this layout (TOP, CENTER, or BOTTOM). |
int |
getHgap()
Returns the horizontal gap between components. |
int |
getVgap()
Returns the vertical gap between components. |
void |
layoutContainer(java.awt.Container target)
Lays out the container. |
java.awt.Dimension |
minimumLayoutSize(java.awt.Container target)
Returns the minimum dimensions needed to layout the components contained in the specified target container. |
java.awt.Dimension |
preferredLayoutSize(java.awt.Container target)
Returns the preferred dimensions for this layout given the components in the specified target container. |
void |
removeLayoutComponent(java.awt.Component comp)
Removes the specified component from the layout. |
void |
setAlignment(int align)
Sets the alignment value for this 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 the string representation of this layout's values. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
public static final int TOP
public static final int CENTER
public static final int BOTTOM
| Constructor Detail |
public VerticalFlowLayout()
public VerticalFlowLayout(int align)
align - the alignment value
public VerticalFlowLayout(int align,
int hgap,
int vgap)
align - the alignment valuehgap - the horizontal gap variablevgap - the vertical gap variable
public VerticalFlowLayout(int align,
int hgap,
int vgap,
boolean maximise)
align - the alignment valuehgap - the horizontal gap variablevgap - the vertical gap variable| Method Detail |
public int getAlignment()
public void setAlignment(int align)
align - the alignment value (TOP, CENTER, or BOTTOM).public 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 components
public void addLayoutComponent(java.lang.String name,
java.awt.Component comp)
addLayoutComponent in interface java.awt.LayoutManagername - the name of the componentcomp - the the component to be addedpublic void removeLayoutComponent(java.awt.Component comp)
removeLayoutComponent in interface java.awt.LayoutManagercomp - the component to removepublic java.awt.Dimension preferredLayoutSize(java.awt.Container target)
preferredLayoutSize in interface java.awt.LayoutManagertarget - the component which needs to be laid outContainer,
minimumLayoutSize(java.awt.Container)public java.awt.Dimension minimumLayoutSize(java.awt.Container target)
minimumLayoutSize in interface java.awt.LayoutManagertarget - the component which needs to be laid outpreferredLayoutSize(java.awt.Container)public void layoutContainer(java.awt.Container target)
layoutContainer in interface java.awt.LayoutManagertarget - the specified component being laid out.Containerpublic java.lang.String toString()
toString in class java.lang.Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||