|
||||||||||
| PREV CLASS Documentation homepage NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JLabel
javax.swing.table.DefaultTableCellRenderer
ilog.cpl.table.IlpTableHeaderRenderer
public class IlpTableHeaderRenderer
Table header renderer used to display the header, the sorting order,
and the sorting direction of the columns of an IlpTableView.
This renderer uses the Cascading Style Sheets mechanism to display the
contents of the cell header.
It uses the following CSS properties:
iconVisible to decide whether to display an icon. This property
does not act on the icon showing the sort criterion.icon to find out the icon to display. If the value of
this property is null, no icon is displayed. The icon, if not null,
will be concatenated with the icon showing the sort criterion.labelVisible to decide whether to display the label text.label to define the label text to display. If
the value of this property is null, the attribute name will be used instead.labelFont is used for the font in which to display the label text.
If the value of this property is null, the font of the header containing
the cell being rendered will be used instead.labelSpacing specifies the gap (in pixels) between the icon and
the text.labelPosition specifies the position of the text relative to
the icon.labelInsets specifies insets (in pixels) of the cell.horizontalAlignment specifies the horizontal alignment
for the group icon + text.verticalAlignment specifies the vertical alignment
for the group icon + text.background is used to determine the background
color of the cell.
If the value of this property is null, the background of the header containing
the cell being rendered will be used instead.foreground is used to determine the foreground
color of the label text.
If the value of this property is null, the foreground of the header containing
the cell being rendered will be used instead.toolTipText defines the tooltip of the cell. If the value
of this property is null, no tooltip will be displayed.Note that tooltips are managed by the tooltip manager
IlpToolTipManager.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class javax.swing.table.DefaultTableCellRenderer |
|---|
DefaultTableCellRenderer.UIResource |
| Nested classes/interfaces inherited from class javax.swing.JLabel |
|---|
JLabel.AccessibleJLabel |
| Nested classes/interfaces inherited from class javax.swing.JComponent |
|---|
JComponent.AccessibleJComponent |
| Nested classes/interfaces inherited from class java.awt.Container |
|---|
Container.AccessibleAWTContainer |
| Nested classes/interfaces inherited from class java.awt.Component |
|---|
Component.AccessibleAWTComponent, Component.BltBufferStrategy, Component.FlipBufferStrategy |
| Field Summary | |
|---|---|
static int |
ICON_OFFSET
Offset between two icons. |
| Fields inherited from class javax.swing.table.DefaultTableCellRenderer |
|---|
noFocusBorder |
| Fields inherited from class javax.swing.JLabel |
|---|
labelFor |
| 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 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 | |
|---|---|
IlpTableHeaderRenderer(IlpTableView ilpTableView)
Constructs an IlpTableHeaderRenderer. |
|
| Method Summary | |
|---|---|
protected TableCellRenderer |
getLastResortRenderer()
Returns the renderer that will be used as a last resort if a problem occurs in the rendering of a cell. |
Component |
getTableCellRendererComponent(JTable table,
Object value,
boolean isSelected,
boolean hasFocus,
int row,
int column)
Called when the table needs to display a cell. |
| Methods inherited from class javax.swing.table.DefaultTableCellRenderer |
|---|
firePropertyChange, firePropertyChange, invalidate, isOpaque, repaint, repaint, repaint, revalidate, setBackground, setForeground, setValue, updateUI, validate |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static int ICON_OFFSET
| Constructor Detail |
|---|
public IlpTableHeaderRenderer(IlpTableView ilpTableView)
IlpTableHeaderRenderer.
ilpTableView - The table that uses this renderer.| Method Detail |
|---|
public Component getTableCellRendererComponent(JTable table,
Object value,
boolean isSelected,
boolean hasFocus,
int row,
int column)
getTableCellRendererComponent in interface TableCellRenderergetTableCellRendererComponent in class DefaultTableCellRenderertable - The table that displays the cell.value - The value to be displayed in the cell.isSelected - Specifies whether the cell is to be displayed selected.hasFocus - Specifies whether the cell is to be displayed with focus.row - The index of the row to be displayed.column - The index of the column to be displayed.
protected TableCellRenderer getLastResortRenderer()
|
||||||||||
| PREV CLASS Documentation homepage NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||