org.basex.gui.layout
Class TableLayout

java.lang.Object
  extended by org.basex.gui.layout.TableLayout
All Implemented Interfaces:
java.awt.LayoutManager

public final class TableLayout
extends java.lang.Object
implements java.awt.LayoutManager

This LayoutManager is similar to the GridLayout. The added components keep their minimum size even when the parent container is resized.

Author:
BaseX Team 2005-12, BSD License, Christian Gruen

Constructor Summary
TableLayout(int r, int c)
          Creates a grid layout with the specified number of rows and columns.
TableLayout(int r, int c, int ix, int iy)
          Creates a grid layout with the specified number of rows and columns.
 
Method Summary
 void addLayoutComponent(java.lang.String name, java.awt.Component comp)
           
 void layoutContainer(java.awt.Container p)
           
 java.awt.Dimension minimumLayoutSize(java.awt.Container parent)
           
 java.awt.Dimension preferredLayoutSize(java.awt.Container parent)
           
 void removeLayoutComponent(java.awt.Component comp)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TableLayout

public TableLayout(int r,
                   int c)
Creates a grid layout with the specified number of rows and columns. When displayed, the grid has the minimum size.

Parameters:
r - number of rows
c - number of columns

TableLayout

public TableLayout(int r,
                   int c,
                   int ix,
                   int iy)
Creates a grid layout with the specified number of rows and columns. When displayed, the grid has the minimum size.

Parameters:
r - number of rows
c - number of columns
ix - horizontal gap
iy - vertical gap
Method Detail

addLayoutComponent

public void addLayoutComponent(java.lang.String name,
                               java.awt.Component comp)
Specified by:
addLayoutComponent in interface java.awt.LayoutManager

removeLayoutComponent

public void removeLayoutComponent(java.awt.Component comp)
Specified by:
removeLayoutComponent in interface java.awt.LayoutManager

preferredLayoutSize

public java.awt.Dimension preferredLayoutSize(java.awt.Container parent)
Specified by:
preferredLayoutSize in interface java.awt.LayoutManager

minimumLayoutSize

public java.awt.Dimension minimumLayoutSize(java.awt.Container parent)
Specified by:
minimumLayoutSize in interface java.awt.LayoutManager

layoutContainer

public void layoutContainer(java.awt.Container p)
Specified by:
layoutContainer in interface java.awt.LayoutManager