|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.GridLayout com.cosylab.gui.components.util.CosyUIElements.FillingGridLayout
public static final class CosyUIElements.FillingGridLayout
Constructor Summary | |
---|---|
CosyUIElements.FillingGridLayout()
Creates a grid layout with a default of one column per component, in a single row. |
|
CosyUIElements.FillingGridLayout(int rows,
int cols)
Creates a grid layout with the specified number of rows and columns. |
|
CosyUIElements.FillingGridLayout(int rows,
int cols,
int hgap,
int vgap)
Creates a grid layout with the specified number of rows and columns. |
Method Summary | |
---|---|
void |
layoutContainer(java.awt.Container parent)
Lays out the specified container using this layout. |
Methods inherited from class java.awt.GridLayout |
---|
addLayoutComponent, getColumns, getHgap, getRows, getVgap, minimumLayoutSize, preferredLayoutSize, removeLayoutComponent, setColumns, setHgap, setRows, setVgap, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public CosyUIElements.FillingGridLayout()
public CosyUIElements.FillingGridLayout(int rows, int cols)
One, but not both, of rows
and cols
can
be zero, which means that any number of objects can be placed in a
row or in a column.
rows
- the rows, with the value zero meaning
any number of rows.cols
- the columns, with the value zero meaning
any number of columns.public CosyUIElements.FillingGridLayout(int rows, int cols, int hgap, int vgap)
In addition, the horizontal and vertical gaps are set to the specified values. Horizontal gaps are placed at the left and right edges, and between each of the columns. Vertical gaps are placed at the top and bottom edges, and between each of the rows.
One, but not both, of rows
and cols
can
be zero, which means that any number of objects can be placed in a
row or in a column.
All GridLayout
constructors defer to this one.
rows
- the rows, with the value zero meaning
any number of rowscols
- the columns, with the value zero meaning
any number of columnshgap
- the horizontal gapvgap
- the vertical gap
java.lang.IllegalArgumentException
- if the value of both
rows
and cols
is
set to zeroMethod Detail |
---|
public void layoutContainer(java.awt.Container parent)
This method reshapes the components in the specified target
container in order to satisfy the constraints of the
GridLayout
object.
The grid layout manager determines the size of individual components by dividing the free space in the container into equal-sized portions according to the number of rows and columns in the layout. The container's free space equals the container's size minus any insets and any specified horizontal or vertical gap. All components in a grid layout are given the same size.
layoutContainer
in interface java.awt.LayoutManager
layoutContainer
in class java.awt.GridLayout
target
- the container in which to do the layoutContainer
,
Container.doLayout()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |