V
- Type of data stored in each table cellTableCellRenderer<V>
public class DefaultTableCellRenderer<V> extends Object implements TableCellRenderer<V>
TableCellRenderer
Constructor | Description |
---|---|
DefaultTableCellRenderer() |
Modifier and Type | Method | Description |
---|---|---|
void |
drawCell(Table<V> table,
V cell,
int columnIndex,
int rowIndex,
TextGUIGraphics textGUIGraphics) |
Called by the table when it's time to draw a cell, you can see how much size is available by checking the size of
the
textGUIGraphics . |
TerminalSize |
getPreferredSize(Table<V> table,
V cell,
int columnIndex,
int rowIndex) |
Called by the table when it wants to know how big a particular table cell should be
|
public TerminalSize getPreferredSize(Table<V> table, V cell, int columnIndex, int rowIndex)
TableCellRenderer
getPreferredSize
in interface TableCellRenderer<V>
table
- Table containing the cellcell
- Data stored in the cellcolumnIndex
- Column index of the cellrowIndex
- Row index of the cellpublic void drawCell(Table<V> table, V cell, int columnIndex, int rowIndex, TextGUIGraphics textGUIGraphics)
TableCellRenderer
textGUIGraphics
. The top-left position of the graphics object is the top-left position of this cell.drawCell
in interface TableCellRenderer<V>
table
- Table containing the cellcell
- Data stored in the cellcolumnIndex
- Column index of the cellrowIndex
- Row index of the celltextGUIGraphics
- Graphics object to draw withCopyright © 2020. All rights reserved.