org.apache.pivot.wtk.content
Class TableViewBooleanCellRenderer
java.lang.Object
org.apache.pivot.wtk.Component
org.apache.pivot.wtk.Container
org.apache.pivot.wtk.BoxPane
org.apache.pivot.wtk.content.TableViewBooleanCellRenderer
- All Implemented Interfaces:
- Iterable<Component>, Sequence<Component>, ConstrainedVisual, Renderer, TableView.CellRenderer, Visual
public class TableViewBooleanCellRenderer
- extends BoxPane
- implements TableView.CellRenderer
Default renderer for table view cells that contain boolean data. Renders
cell contents as a checkbox.
Methods inherited from class org.apache.pivot.wtk.Container |
add, clear, containsFocus, descendantAdded, descendantGainedFocus, descendantLostFocus, descendantRemoved, get, getComponentAt, getContainerListeners, getContainerMouseListeners, getDescendantAt, getFocusTraversalPolicy, getLength, indexOf, insert, isAncestor, iterator, layout, load, mouseClick, mouseDown, mouseMove, mouseOut, mouseUp, mouseWheel, move, paint, remove, remove, removeAll, requestFocus, setFocusTraversalPolicy, setParent, setVisible, store, transferFocus, update |
Methods inherited from class org.apache.pivot.wtk.Component |
clearFocus, getAncestor, getAttribute, getAutomationID, getBaseline, getBaseline, getBounds, getComponentClassListeners, getComponentDataListeners, getComponentDecoratorListeners, getComponentKeyListeners, getComponentListeners, getComponentMouseButtonListeners, getComponentMouseListeners, getComponentMouseWheelListeners, getComponentStateListeners, getCursor, getDecoratedBounds, getDecorators, getDisplay, getDragSource, getDropTarget, getFocusedComponent, getGraphics, getHeight, getLocation, getMaximumPreferredHeight, getMaximumPreferredWidth, getMenuHandler, getMinimumPreferredHeight, getMinimumPreferredWidth, getParent, getPreferredHeight, getPreferredHeight, getPreferredHeightLimits, getPreferredSize, getPreferredWidth, getPreferredWidth, getPreferredWidthLimits, getSize, getSkin, getStyles, getTooltipText, getUserData, getVisibleArea, getVisibleArea, getVisibleArea, getWidth, getWindow, getX, getY, installThemeSkin, invalidate, isBlocked, isEnabled, isFocusable, isFocused, isMouseOver, isOpaque, isPreferredHeightSet, isPreferredSizeSet, isPreferredWidthSet, isShowing, isValid, isVisible, keyPressed, keyReleased, keyTyped, mapPointFromAncestor, mapPointFromAncestor, mapPointToAncestor, mapPointToAncestor, mouseOver, reenterMouse, repaint, repaint, repaint, repaint, repaint, repaint, scrollAreaToVisible, scrollAreaToVisible, setAttribute, setAutomationID, setCursor, setCursor, setDragSource, setDropTarget, setEnabled, setHeight, setLocation, setLocation, setMaximumPreferredHeight, setMaximumPreferredWidth, setMenuHandler, setMinimumPreferredHeight, setMinimumPreferredWidth, setPreferredHeight, setPreferredHeightLimits, setPreferredHeightLimits, setPreferredSize, setPreferredSize, setPreferredWidth, setPreferredWidthLimits, setPreferredWidthLimits, setSize, setSkin, setStyles, setStyles, setStyles, setTooltipText, setWidth, setX, setY, toString, transferFocus, validate |
TableViewBooleanCellRenderer
public TableViewBooleanCellRenderer()
setSize
public void setSize(int width,
int height)
- Description copied from class:
Component
- NOTE This method should only be called during layout. Callers should
use
Component.setPreferredSize(int, int)
.
- Specified by:
setSize
in interface ConstrainedVisual
- Overrides:
setSize
in class Component
render
public void render(Object row,
int rowIndex,
int columnIndex,
TableView tableView,
String columnName,
boolean selected,
boolean highlighted,
boolean disabled)
- Description copied from interface:
TableView.CellRenderer
- Prepares the renderer for layout or paint.
- Specified by:
render
in interface TableView.CellRenderer
- Parameters:
row
- The row to render, or null if called to calculate preferred height for
skins that assume a fixed renderer height.rowIndex
- The index of the row being rendered, or -1 if value
is null.columnIndex
- The index of the column being rendered.tableView
- The host component.columnName
- The name of the column being rendered.selected
- If true, the row is selected.highlighted
- If true, the row is highlighted.disabled
- If true, the row is disabled.
toString
public String toString(Object row,
String columnName)
- Description copied from interface:
TableView.CellRenderer
- Converts table view cell data to a string representation.
- Specified by:
toString
in interface TableView.CellRenderer
- Returns:
- The cell data's string representation, or null if the data does not
have a string representation.
Note that this method may be called often during keyboard navigation, so
implementations should avoid unnecessary string allocations.
isCheckboxDisabled
public boolean isCheckboxDisabled()
setCheckboxDisabled
public void setCheckboxDisabled(boolean checkboxDisabled)