|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.awt.GridLayout
org.vizzini.ui.GridLayout2
public class GridLayout2
Provides a layout manager which extends GridLayout to allow the cells to be different sizes. Taken from Java World Tip #121: Flex Your Grid Layout.
Constructor Summary | |
---|---|
GridLayout2()
Construct this object. |
|
GridLayout2(int rows,
int cols)
Construct this object with the given parameters. |
|
GridLayout2(int rows,
int cols,
int hgap,
int vgap)
Construct this object with the given parameters. |
Method Summary | |
---|---|
void |
layoutContainer(Container parent)
Lays out the specified container using this layout. |
Dimension |
minimumLayoutSize(Container parent)
Determines the minimum size of the container argument using this grid layout. |
Dimension |
preferredLayoutSize(Container parent)
Determines the preferred size of the container argument using this grid layout. |
Methods inherited from class java.awt.GridLayout |
---|
addLayoutComponent, getColumns, getHgap, getRows, getVgap, 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 GridLayout2()
public GridLayout2(int rows, int cols)
rows
- Number of rows, with the value zero meaning any number of
rows.cols
- Number of columns, with the value zero meaning any number
of columns.public GridLayout2(int rows, int cols, int hgap, int vgap)
rows
- Number of rows, with the value zero meaning any number of
rows.cols
- Number of columns, with the value zero meaning any number
of columns.hgap
- Horizontal gap.vgap
- Vertical gap.Method Detail |
---|
public void layoutContainer(Container parent)
layoutContainer
in interface LayoutManager
layoutContainer
in class GridLayout
parent
- The container in which to do the layout.public Dimension minimumLayoutSize(Container parent)
minimumLayoutSize
in interface LayoutManager
minimumLayoutSize
in class GridLayout
parent
- The container in which to do the layout.public Dimension preferredLayoutSize(Container parent)
preferredLayoutSize
in interface LayoutManager
preferredLayoutSize
in class GridLayout
parent
- The container in which to do the layout.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright © 2007 Vizzini.org. All Rights Reserved. | 2007.12.25.03.00.02 |