|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.javagl.swogl.layout.GridLayout3D
public class GridLayout3D
An implementation of the LayoutManager3D interface that lays out the SwoglComponents in a grid. Double-clicking a component zooms the component to unit size and centers it. Double-clicking with the right mouse button (or outside of a SwoglComponent) zooms out to make all components visible.
Constructor Summary | |
---|---|
GridLayout3D(int rows,
int columns)
Creates a new GridLayout3D that lays out the SwoglComponents of a SwoglContainer in a grid with the given number of rows and columns and with no space between the components. |
|
GridLayout3D(int rows,
int columns,
int hGap,
int vGap)
Creates a new GridLayout3D that lays out the SwoglComponents of a SwoglContainer in a grid with the given number of rows and columns and with the given spacing between the components. |
Method Summary | |
---|---|
void |
doLayout3D()
Lays out the SwoglComponents in a SwoglContainer |
void |
setSwoglContainer(SwoglContainer swoglContainer)
This method will assign the given SwoglContainer to this LayoutManager3D. |
void |
zoomTo(SwoglComponent swoglComponent)
Zoom to the given SwoglComponent. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public GridLayout3D(int rows, int columns, int hGap, int vGap)
rows
- The rows of the gridcolumns
- The columns of the grid.hGap
- The horizontal gap between componentsvGap
- The vertical gap between componentspublic GridLayout3D(int rows, int columns)
rows
- The rows of the gridcolumns
- The columns of the grid.Method Detail |
---|
public void setSwoglContainer(SwoglContainer swoglContainer)
LayoutManager3D
SwoglContainer.setLayout3D(LayoutManager3D)
method,
the SwoglContainer will pass itself to this method. When a
different LayoutManager3D is assigned to the SwoglContainer,
then the SwoglContainer will call this method and pass 'null'
as the argument. This allows implementations of this interface
to perform an initialization when this LayoutManager3D becomes
assigned to a SwoglContainer, and necessary cleanup operations
when they are detached from a SwoglContainer.
setSwoglContainer
in interface LayoutManager3D
swoglContainer
- The SwoglContainer for this LayoutManager3Dpublic void doLayout3D()
LayoutManager3D
doLayout3D
in interface LayoutManager3D
public void zoomTo(SwoglComponent swoglComponent)
swoglComponent
- The SwoglComponent to zoom to.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |