|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.google.gwt.user.client.ui.UIObject
com.google.gwt.user.client.ui.Widget
com.google.gwt.user.client.ui.Panel
com.google.gwt.user.client.ui.HTMLTable
com.google.gwt.user.client.ui.Grid
A rectangular grid that can contain text, html, or a child
Widget within its cells. It must be
resized explicitly to the desired number of rows and columns.
code
| Nested Class Summary |
| Nested classes inherited from class com.google.gwt.user.client.ui.HTMLTable |
HTMLTable.CellFormatter, HTMLTable.RowFormatter |
| Field Summary | |
protected int |
numColumns
|
protected int |
numRows
|
| Fields inherited from class java.lang.Object |
typeId, typeName |
| Constructor Summary | |
Grid()
|
|
Grid(int rows,
int columns)
Constructs a grid with the requested size. |
|
| Method Summary | |
boolean |
clearCell(int row,
int column)
Replaces the contents of the specified cell with a single space. |
protected Element |
createCell()
Creates a new, empty cell. |
int |
getCellCount(int row)
Return number of columns. |
int |
getColumnCount()
Gets the number of columns in this grid. |
int |
getRowCount()
Return number of rows |
protected void |
prepareCell(int row,
int column)
Checks that a cell is a valid cell in the table. |
protected void |
prepareRow(int row)
Checks that the row index is valid. |
void |
resize(int rows,
int columns)
Resizes the grid. |
void |
resizeColumns(int columns)
Resizes the grid to the specified number of columns. |
void |
resizeRows(int rows)
Resizes the grid to the specified number of rows. |
| Methods inherited from class com.google.gwt.user.client.ui.HTMLTable |
add, addTableListener, checkCellBounds, checkRowBounds, clear, computeKey, getBodyElement, getCellFormatter, getCellPadding, getCellSpacing, getDOMCellCount, getDOMRowCount, getHTML, getRowFormatter, getText, getWidget, insertCell, insertCells, insertRow, internalClearCell, isCellPresent, iterator, onBrowserEvent, remove, removeCell, removeRow, removeTableListener, setBorderWidth, setCellFormatter, setCellPadding, setCellSpacing, setHTML, setRowFormatter, setText, setWidget |
| Methods inherited from class com.google.gwt.user.client.ui.Panel |
adopt, disown, onAttach, onDetach |
| Methods inherited from class com.google.gwt.user.client.ui.Widget |
getParent, isAttached, onLoad |
| Methods inherited from class com.google.gwt.user.client.ui.UIObject |
addStyleName, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleName, isVisible, isVisible, removeStyleName, setElement, setHeight, setPixelSize, setSize, setStyleName, setStyleName, setVisible, setVisible, setWidth, sinkEvents, toString, unsinkEvents |
| Methods inherited from class java.lang.Object |
equals, finalize, hashCode |
| Field Detail |
protected int numColumns
protected int numRows
| Constructor Detail |
public Grid()
public Grid(int rows,
int columns)
rows - the number of rowscolumns - the number of columns
IndexOutOfBoundsException| Method Detail |
public boolean clearCell(int row,
int column)
clearCell in class HTMLTablerow - the cell's rowcolumn - the widget's column
IndexOutOfBoundsExceptionpublic int getCellCount(int row)
getCellCount in class HTMLTablerow - the row whose cells are to be counted
public int getColumnCount()
public int getRowCount()
getRowCount in class HTMLTable
public void resize(int rows,
int columns)
rows - the number of rowscolumns - the number of columns
IndexOutOfBoundsExceptionpublic void resizeColumns(int columns)
columns - the number of columns
IndexOutOfBoundsExceptionpublic void resizeRows(int rows)
rows - the number of rows
IndexOutOfBoundsExceptionprotected Element createCell()
createCell in class HTMLTable
protected void prepareCell(int row,
int column)
prepareCell in class HTMLTablerow - the cell's rowcolumn - the cell's column
IndexOutOfBoundsExceptionprotected void prepareRow(int row)
prepareRow in class HTMLTablerow - The row index to be checked
IndexOutOfBoundException - if the row is negative
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||