|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--java.awt.Component
|
+--java.awt.Container
|
+--javax.swing.JComponent
|
+--javax.swing.JPanel
|
+--edu.neu.ccs.gui.DisplayPanel
|
+--edu.neu.ccs.gui.TablePanel
A DisplayPanel designed to use a TableLayout as
its layout manager.
The method setLayout is overridden so that it is
impossible to change the layout manager to any other layout.
TableLayout,
Serialized Form| Field Summary | |
static int |
DEFAULT_ALIGNMENT
Value of the default cell alignment. |
static int |
DEFAULT_ORIENTATION
Value of the default cell alignment. |
protected TableGenerator |
tg
Generator used to produce the content for this table. |
| Fields inherited from class edu.neu.ccs.gui.DisplayPanel |
background, codec, CODEC |
| Fields inherited from class javax.swing.JComponent |
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface edu.neu.ccs.gui.Displayable |
DEFAULT_VIEW_STATE, VIEW_STATE |
| Fields inherited from interface edu.neu.ccs.util.JPTConstants |
ABOVE, ALIGNMENT, BELOW, BOTTOM_LEFT, BOTTOM_RIGHT, DEFAULT, FONT, INPUT_PROPERTIES, MANDATORY, OPTIONAL, ORIENTATION, TOP_LEFT, TOP_RIGHT |
| Fields inherited from interface javax.swing.SwingConstants |
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST |
| Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
TablePanel()
Constructs a default table panel. |
|
TablePanel(int align)
Constructs a table panel with the given cell alignment. |
|
TablePanel(int rows,
int cols)
Constructs a table panel with the given number of rows and columns. |
|
TablePanel(int rows,
int cols,
int align)
Constructs a table panel with the given number of rows and columns, and the given cell alignment. |
|
TablePanel(int rows,
int cols,
int hgap,
int vgap)
Constructs a table panel with the given number of rows and columns, and the given horizontal and vertical gaps between cells. |
|
TablePanel(int rows,
int cols,
int hgap,
int vgap,
int align)
Constructs a table panel with the given number of rows and columns, the given horizontal and vertical gaps between cells, and the given cell alignment. |
|
TablePanel(int rows,
int cols,
int hgap,
int vgap,
int align,
int orientation)
Constructs a table panel with the given number of rows and columns, the given horizontal and vertical gaps between cells, the given cell alignment, and the given table layout orientation. |
|
TablePanel(Object[][] contents)
Constructs a table panel containing the given table of objects, with the default cell alignment and a VERTICAL orientation. |
|
TablePanel(Object[][] contents,
int align)
Constructs a table panel containing the given table of objects and the given cell alignment, with the default cell alignment and a VERTICAL orientation. |
|
TablePanel(Object[][] contents,
int hgap,
int vgap)
Constructs a table panel containing the given table of objects, with the given horizontal and vertical gaps between cells, the default cell alignment, and a VERTICAL orientation. |
|
TablePanel(Object[][] contents,
int hgap,
int vgap,
int align)
Constructs a table panel containing the given table of objects, with the given horizontal and vertical gaps between cells, the given cell alignment, and a VERTICAL orientation. |
|
TablePanel(Object[] contents,
int orientation)
Constructs a table panel containing the given objects in the given orientation. |
|
TablePanel(Object[] contents,
int orientation,
int align)
Constructs a table panel containing the given objects in the given orientation, with the given cell alignment. |
|
TablePanel(Object[] contents,
int orientation,
int hgap,
int vgap)
Constructs a table panel containing the given objects in the given orientation, with the given horizontal and vertical gaps between cells. |
|
TablePanel(Object[] contents,
int orientation,
int hgap,
int vgap,
int align)
Constructs a table panel containing the given objects in the given orientation, with the given horizontal and vertical gaps between cells and the given cell alignment. |
|
TablePanel(TableGenerator tg,
int rows,
int cols)
Constructs a table panel constructed from the given table generator and given rows and cols. |
|
TablePanel(TableGenerator tg,
int rows,
int cols,
int align)
Constructs a table panel constructed from the given table generator, the given rows and cols, and the given cell alignment. |
|
TablePanel(TableGenerator tg,
int rows,
int cols,
int hgap,
int vgap)
Constructs a table panel constructed from the given table generator, the given rows and cols, and the given horizontal and vertical gaps between cells. |
|
TablePanel(TableGenerator tg,
int rows,
int cols,
int hgap,
int vgap,
int align)
Constructs a table panel constructed from the given table generator, the given rows and cols, the given horizontal and vertical gaps between cells, and the given cell alignment. |
|
| Method Summary | |
Component |
addObject(Object object,
int row,
int col)
Add the given object to this TablePanel
at the position specified by the row and column
after applying the transformation of the method
makeComponent. |
protected void |
createCells(int loRows,
int loCols,
int hiRows,
int hiCols)
Create the table cells at position (row, col) for loRows <= row < hiRows and loCols <= col < hiCols. |
int |
getCellAlignment(CellPosition p)
Returns the alignment value for the cell at the given position or the table alignment if an error occurs. |
int |
getCellAlignment(int row,
int col)
Returns the alignment value for the cell at the given position or the table alignment if an error occurs. |
int |
getColumnAlignment(int col)
Returns the default alignment value for the given column. |
int |
getColumnCount()
Returns the number of columns in this table panel. |
Component[][] |
getComponentTable()
Returns a copy of the table of components in this panel. |
int |
getEffectiveCellAlignment(CellPosition p)
Returns the effective alignment value for the cell at the given position, that is, either the cell's own alignment if it has been set or the alignment of the table as a whole. |
int |
getEffectiveCellAlignment(int row,
int col)
Returns the effective alignment value for the cell at the given position, that is, either the cell's own alignment if it has been set or the alignment of the table as a whole. |
int |
getHorizontalGap()
Returns the gap, in pixels, between columns in this table panel. |
Dimension |
getMaximumSize()
Return the maximum size of the table as computed by the table layout. |
int |
getMinimumColumnWidth(int col)
Returns the minimum width set for the given column. |
int |
getMinimumRowHeight(int row)
Returns the minimum height set for the given row. |
Dimension |
getMinimumSize()
Return the minimum size of the table as computed by the table layout. |
int |
getOrientation()
Returns the orientation for the layout of this table. |
Dimension |
getPreferredSize()
Return the preferred size of the table as computed by the table layout. |
int |
getRowAlignment(int row)
Returns the default alignment value for the given row. |
int |
getRowCount()
Returns the number of rows in this table panel. |
int |
getTableAlignment()
Returns the default alignment for cells in this table panel. |
Component |
getTableEntry(CellPosition p)
Returns the component at the given CellPosition
in the table or null if no such component exists. |
Component |
getTableEntry(int row,
int col)
Returns the component at the position row,col in the table or null if no such component exists. |
TableGenerator |
getTableGenerator()
Returns the table generator used to create the components of this table or null if no generator is being used. |
TableLayout |
getTableLayout()
Returns the TableLayout managing this panel. |
int |
getVerticalGap()
Returns the gap, in pixels, between rows in this table panel. |
boolean |
isEmptyColumn(int col)
Returns whether or not the given column is empty. |
boolean |
isEmptyRow(int row)
Returns whether or not the given row is empty. |
boolean |
isValidColumn(int col)
Returns whether or not the given column index is valid. |
boolean |
isValidRow(int row)
Returns whether or not the given row index is valid. |
protected void |
removeCells(int loRows,
int loCols,
int hiRows,
int hiCols)
Remove the table cells at position (row, col) for loRows <= row < hiRows and loCols <= col < hiCols. |
protected void |
resetPreferredSize()
Sets the preferred size for this panel to its preferred size, and updates the screen UI. |
void |
setAllMinimumColumnWidths(int width)
Sets all minimum column widths to the same value. |
void |
setAllMinimumRowHeights(int height)
Sets all minimum row heights to the same value. |
void |
setCellAlignment(CellPosition p,
int align)
Sets the alignment for the cell at the given position to the given alignment value. |
void |
setCellAlignment(int row,
int col,
int align)
Sets the alignment for the cell at the given position to the given alignment value. |
void |
setColumnAlignment(int col,
int align)
Sets the alignment for cells in the given column to the given alignment value. |
void |
setColumns(int cols)
Change the number of columns in the table to the given value but ignore invalid parameter values less than 0. |
void |
setHorizontalGap(int hgap)
Sets the gap between columns in this table panel to the given value, in pixels. |
void |
setLayout(LayoutManager manager)
Overrides the setLayout method to do nothing so that the user of TablePanel cannot change its layout. |
void |
setMinimumColumnWidth(int col,
int width)
Sets the minimum width for the given column to the given width in pixels. |
void |
setMinimumRowHeight(int row,
int height)
Sets the minimum height for the given row to the given height in pixels. |
void |
setOrientation(int orientation)
Sets the orientation for the layout of this table to the given orientation value. |
void |
setRowAlignment(int row,
int align)
Sets the alignment for cells in the given row to the given alignment value. |
void |
setRows(int rows)
Change the number of rows in the table to the given value but ignore invalid parameter values less than 0. |
void |
setTableAlignment(int align)
Sets the alignment for cells in this table panel to the given alignment value. |
void |
setVerticalGap(int vgap)
Sets the gap between rows in this table panel to the given value, in pixels. |
void |
uniformizeCellHeight()
Sets the table cell height for all cells in this panel to the same width. |
void |
uniformizeCellSize()
Sets the table cell size for all cells in this panel to the same size. |
void |
uniformizeCellWidth()
Sets the table cell width for all cells in this panel to the same width. |
| Methods inherited from class edu.neu.ccs.gui.DisplayPanel |
add, add, add, add, add, addObject, addObject, addObject, addObject, dataMalformed, endAlert, frame, frame, frame, frame, frame, frame, generalDialog, generalDialog, generalDialog, generalDialog, getCodec, getDefaultViewState, getViewState, makeComponent, OKCancelDialog, OKCancelDialog, OKDialog, OKDialog, refreshComponent, remove, remove, removeAll, reset, setCodec, setDefaultViewState, setEnabled, setViewState, startAlert, uniformizeHeight, uniformizeSize, uniformizeWidth, YesNoCancelDialog, YesNoCancelDialog |
| Methods inherited from class javax.swing.JPanel |
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
public static final int DEFAULT_ALIGNMENT
public static final int DEFAULT_ORIENTATION
protected TableGenerator tg
| Constructor Detail |
public TablePanel()
TablePanel(int),
TablePanel(int, int),
TablePanel(int, int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int),
TablePanel(Object[], int, int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int)public TablePanel(int align)
align - the alignment of a component within a table cellTablePanel(),
TablePanel(int, int),
TablePanel(int, int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int),
TablePanel(Object[], int, int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int),
JPTConstants.DEFAULT
public TablePanel(int rows,
int cols)
rows - the number of rows in the tablecols - the number of columns in the tableTablePanel(),
TablePanel(int),
TablePanel(int, int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int),
TablePanel(Object[], int, int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int)
public TablePanel(int rows,
int cols,
int align)
rows - the number of rows in the tablecols - the number of columns in the tablealign - the alignment of a component within a table cellTablePanel(),
TablePanel(int),
TablePanel(int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int),
TablePanel(Object[], int, int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int),
JPTConstants.DEFAULT
public TablePanel(int rows,
int cols,
int hgap,
int vgap)
rows - the number of rows in the tablecols - the number of columns in the tablehgap - the horizontal gap between columnsvgap - the vertical gap between rowsTablePanel(),
TablePanel(int),
TablePanel(int, int),
TablePanel(int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int),
TablePanel(Object[], int, int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int)
public TablePanel(int rows,
int cols,
int hgap,
int vgap,
int align)
rows - the number of rows in the tablecols - the number of columns in the tablehgap - the horizontal gap between columnsvgap - the vertical gap between rowsalign - the alignment of a component within a table cellTablePanel(),
TablePanel(int),
TablePanel(int, int),
TablePanel(int, int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int),
TablePanel(Object[], int, int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int),
JPTConstants.DEFAULT
public TablePanel(int rows,
int cols,
int hgap,
int vgap,
int align,
int orientation)
rows - the number of rows in the tablecols - the number of columns in the tablehgap - the horizontal gap between columnsvgap - the vertical gap between rowsalign - the alignment of a component within a table cellorientation - the table layout orientationTablePanel(),
TablePanel(int),
TablePanel(int, int),
TablePanel(int, int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int),
TablePanel(Object[], int, int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int),
JPTConstants.DEFAULT
public TablePanel(Object[] contents,
int orientation)
contents - the array of contents to be used to fill the tableorientation - the table orientationTablePanel(),
TablePanel(int),
TablePanel(int, int),
TablePanel(int, int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int),
TablePanel(Object[], int, int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int),
SwingConstants.VERTICAL,
SwingConstants.HORIZONTAL
public TablePanel(Object[] contents,
int orientation,
int align)
contents - the array of contents to be used to fill the tableorientation - the table orientationalign - the alignment of a component within a table cellTablePanel(),
TablePanel(int),
TablePanel(int, int),
TablePanel(int, int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int, int),
TablePanel(Object[], int, int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int),
JPTConstants.DEFAULT
public TablePanel(Object[] contents,
int orientation,
int hgap,
int vgap)
contents - the array of contents to be used to fill the tableorientation - the table orientationhgap - the horizontal gap between columnsvgap - the vertical gap between rowsTablePanel(),
TablePanel(int),
TablePanel(int, int),
TablePanel(int, int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int),
SwingConstants.VERTICAL,
SwingConstants.HORIZONTAL
public TablePanel(Object[] contents,
int orientation,
int hgap,
int vgap,
int align)
contents - the array of contents to be used to fill the tableorientation - the table orientationhgap - the horizontal gap between columnsvgap - the vertical gap between rowsalign - the alignment of a component within a table cellTablePanel(),
TablePanel(int),
TablePanel(int, int),
TablePanel(int, int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int),
JPTConstants.DEFAULTpublic TablePanel(Object[][] contents)
VERTICAL orientation.
contents - the array of contents to be used to fill the tableTablePanel(),
TablePanel(int),
TablePanel(int, int),
TablePanel(int, int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int),
TablePanel(Object[], int, int, int, int),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int)
public TablePanel(Object[][] contents,
int align)
VERTICAL orientation.
contents - the array of contents to be used to fill the tablealign - the alignment of a component within a table cellTablePanel(),
TablePanel(int),
TablePanel(int, int),
TablePanel(int, int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int),
TablePanel(Object[], int, int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int, int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int),
JPTConstants.DEFAULT
public TablePanel(Object[][] contents,
int hgap,
int vgap)
VERTICAL orientation.
contents - the array of contents to be used to fill the tablehgap - the horizontal gap between columnsvgap - the vertical gap between rowsTablePanel(),
TablePanel(int),
TablePanel(int, int),
TablePanel(int, int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int),
TablePanel(Object[], int, int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int)
public TablePanel(Object[][] contents,
int hgap,
int vgap,
int align)
VERTICAL orientation.
contents - the array of contents to be used to fill the tablehgap - the horizontal gap between columnsvgap - the vertical gap between rowsalign - the alignment of a component within a table cellTablePanel(),
TablePanel(int),
TablePanel(int, int),
TablePanel(int, int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int),
TablePanel(Object[], int, int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int),
JPTConstants.DEFAULT
public TablePanel(TableGenerator tg,
int rows,
int cols)
tg - the table generator used to fill the tablerows - the number of rows in the tablecols - the number of columns in the tableTablePanel(),
TablePanel(int),
TablePanel(int, int),
TablePanel(int, int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int),
TablePanel(Object[], int, int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int)
public TablePanel(TableGenerator tg,
int rows,
int cols,
int align)
tg - the table generator used to fill the tablerows - the number of rows in the tablecols - the number of columns in the tablealign - the alignment of a component within a table cellTablePanel(),
TablePanel(int),
TablePanel(int, int),
TablePanel(int, int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int),
TablePanel(Object[], int, int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int),
JPTConstants.DEFAULT
public TablePanel(TableGenerator tg,
int rows,
int cols,
int hgap,
int vgap)
tg - the table generator used to fill the tablerows - the number of rows in the tablecols - the number of columns in the tablehgap - the horizontal gap between columnsvgap - the vertical gap between rowsTablePanel(),
TablePanel(int),
TablePanel(int, int),
TablePanel(int, int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int),
TablePanel(Object[], int, int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int, int),
JPTConstants.DEFAULT
public TablePanel(TableGenerator tg,
int rows,
int cols,
int hgap,
int vgap,
int align)
tg - the table generator used to fill the tablerows - the number of rows in the tablecols - the number of columns in the tablehgap - the horizontal gap between columnsvgap - the vertical gap between rowsalign - the alignment of a component within a table cellTablePanel(),
TablePanel(int),
TablePanel(int, int),
TablePanel(int, int, int),
TablePanel(int, int, int, int),
TablePanel(int, int, int, int, int),
TablePanel(int, int, int, int, int, int),
TablePanel(Object[], int),
TablePanel(Object[], int, int),
TablePanel(Object[], int, int, int),
TablePanel(Object[][]),
TablePanel(Object[][], int),
TablePanel(Object[][], int, int),
TablePanel(Object[][], int, int, int),
TablePanel(TableGenerator, int, int),
TablePanel(TableGenerator, int, int, int),
TablePanel(TableGenerator, int, int, int, int),
JPTConstants.DEFAULT| Method Detail |
public Component addObject(Object object,
int row,
int col)
TablePanel
at the position specified by the row and column
after applying the transformation of the method
makeComponent.
object - the object to be transformed and added to the tablerow - the row in the tablecol - the column in the table
DisplayPanel.addObject(Object, Object),
DisplayPanel.makeComponent(Object)public Component[][] getComponentTable()
public TableGenerator getTableGenerator()
public Component getTableEntry(int row,
int col)
row - the row position of the componentcol - the column position of the componentgetTableEntry(CellPosition)public Component getTableEntry(CellPosition p)
CellPosition
in the table or null if no such component exists.
p - the CellPosition of the componentgetTableEntry(int, int)public void setRows(int rows)
TableGenerator
then fill new cells using this table generator.
rows - the desired number of rowssetColumns(int)public void setColumns(int cols)
TableGenerator
then fill new cells using this table generator.
cols - the desired number of columnssetRows(int)public int getRowCount()
getColumnCount()public int getColumnCount()
getRowCount()public boolean isValidRow(int row)
row - the row in questionisValidColumn(int)public boolean isValidColumn(int col)
col - the column in questionisValidRow(int)public boolean isEmptyRow(int row)
row - the row in questionisEmptyColumn(int)public boolean isEmptyColumn(int col)
col - the column in questionisEmptyRow(int)public void setHorizontalGap(int hgap)
hgap - the desired gap, in pixelsgetHorizontalGap()public int getHorizontalGap()
setHorizontalGap(int)public void setVerticalGap(int vgap)
vgap - the desired gap, in pixelsgetVerticalGap()public int getVerticalGap()
setVerticalGap(int)public void setOrientation(int orientation)
orientation - the orientation for this layoutgetOrientation(),
SwingConstants.HORIZONTAL,
SwingConstants.VERTICAL,
JPTConstants.DEFAULTpublic int getOrientation()
setOrientation(int),
SwingConstants.HORIZONTAL,
SwingConstants.VERTICALpublic void setTableAlignment(int align)
align - the alignment value for cellsgetTableAlignment(),
JPTConstants.DEFAULTpublic int getTableAlignment()
setTableAlignment(int)
public void setRowAlignment(int row,
int align)
row - the row whose alignment is to be setalign - the alignment value for the rowgetRowAlignment(int),
JPTConstants.DEFAULTpublic int getRowAlignment(int row)
row - the row whose alignment value is desiredsetRowAlignment(int, int)
public void setColumnAlignment(int col,
int align)
col - the column whose alignment is to be setalign - the alignment value for the columngetColumnAlignment(int),
JPTConstants.DEFAULTpublic int getColumnAlignment(int col)
col - the column whose alignment value is desiredsetColumnAlignment(int, int)
public void setCellAlignment(CellPosition p,
int align)
p - the position of the cell whose alignment is to be changedalign - the alignment value for the cellsetCellAlignment(int, int, int),
getCellAlignment(CellPosition),
getCellAlignment(int, int),
getEffectiveCellAlignment(CellPosition),
getEffectiveCellAlignment(int, int),
JPTConstants.DEFAULT
public void setCellAlignment(int row,
int col,
int align)
row - the row for the cell whose alignment is to be changedcol - the column for the cell whose alignment is to be changedsetCellAlignment(CellPosition, int),
getCellAlignment(CellPosition),
getCellAlignment(int, int),
getEffectiveCellAlignment(CellPosition),
getEffectiveCellAlignment(int, int),
JPTConstants.DEFAULTpublic int getCellAlignment(CellPosition p)
p - the position of the cell whose alignment value is desiredsetCellAlignment(CellPosition, int),
setCellAlignment(int, int, int),
getCellAlignment(int, int),
getEffectiveCellAlignment(CellPosition),
getEffectiveCellAlignment(int, int),
JPTConstants.DEFAULT
public int getCellAlignment(int row,
int col)
row - the row for the cell whose alignment value is desiredcol - the column for the cell whose alignment value is desiredsetCellAlignment(CellPosition, int),
setCellAlignment(int, int, int),
getCellAlignment(CellPosition),
getEffectiveCellAlignment(CellPosition),
getEffectiveCellAlignment(int, int),
JPTConstants.DEFAULTpublic int getEffectiveCellAlignment(CellPosition p)
p - the position of the cell whose alignment value is desiredsetCellAlignment(CellPosition, int),
setCellAlignment(int, int, int),
getCellAlignment(CellPosition),
getCellAlignment(int, int),
getEffectiveCellAlignment(int, int),
JPTConstants.DEFAULT
public int getEffectiveCellAlignment(int row,
int col)
row - the row for the cell whose alignment value is desiredcol - the column for the cell whose alignment value is desiredsetCellAlignment(CellPosition, int),
setCellAlignment(int, int, int),
getCellAlignment(CellPosition),
getCellAlignment(int, int),
getEffectiveCellAlignment(CellPosition),
JPTConstants.DEFAULT
public void setMinimumRowHeight(int row,
int height)
row - the row whose minimum height is to be setheight - the height for the row in pixels
ArrayOutOfBoundsException - if the given row is invalidgetMinimumRowHeight(int)public int getMinimumRowHeight(int row)
row - the row whose minimum height is desired
ArrayOutOfBoundsException - if the given row is invalidsetMinimumRowHeight(int, int)
public void setMinimumColumnWidth(int col,
int width)
col - the column whose minimum width is to be setwidth - the width for the column in pixels
ArrayOutOfBoundsException - if the given column is invalidgetMinimumColumnWidth(int)public int getMinimumColumnWidth(int col)
col - the column whose minimum width is desired
ArrayOutOfBoundsException - if the given column is invalidsetMinimumColumnWidth(int, int)public void setAllMinimumRowHeights(int height)
setMinimumRowHeight(int, int),
setAllMinimumColumnWidths(int)public void setAllMinimumColumnWidths(int width)
setMinimumColumnWidth(int, int),
setAllMinimumRowHeights(int)public TableLayout getTableLayout()
TableLayout managing this panel.
ClassCastException - if the layout for this panel
is not an instance of TableLayoutpublic void setLayout(LayoutManager manager)
setLayout in class Containermanager - parameter ignoredpublic Dimension getMinimumSize()
getMinimumSize in class JComponentpublic Dimension getPreferredSize()
getPreferredSize in class JComponentpublic Dimension getMaximumSize()
getMaximumSize in class JComponentpublic void uniformizeCellSize()
Sets the table cell size for all cells in this panel to the same size.
The size that is used is created from the widest preferred width and tallest preferred height among the contained components.
public void uniformizeCellWidth()
Sets the table cell width for all cells in this panel to the same width.
The width that is used is created from the widest preferred width among the contained components.
public void uniformizeCellHeight()
Sets the table cell height for all cells in this panel to the same width.
The height that is used is created from the tallest preferred height among the contained components.
protected void createCells(int loRows,
int loCols,
int hiRows,
int hiCols)
TableGenerator.
loRows - the starting row index for generating cellsloCols - the starting column index for generating cellshiRows - the limiting row index for generating cellshiCols - the limiting column index for generating cells
protected void removeCells(int loRows,
int loCols,
int hiRows,
int hiCols)
loRows - the starting row index for generating cellsloCols - the starting column index for generating cellshiRows - the limiting row index for generating cellshiCols - the limiting column index for generating cellsprotected void resetPreferredSize()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||