|
JIDE 3.5.15 | ||||||||
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.table.JTableHeader com.jidesoft.grid.DraggingTableHeader com.jidesoft.grid.CellStyleTableHeader com.jidesoft.grid.SortableTableHeader com.jidesoft.grid.EditableTableHeader com.jidesoft.grid.AutoFilterTableHeader com.jidesoft.grid.NestedTableHeader
public class NestedTableHeader
A table header supporting nested table columns.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class javax.swing.table.JTableHeader |
---|
JTableHeader.AccessibleJTableHeader |
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.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy |
Field Summary | |
---|---|
protected Vector<TableColumn> |
_columnGroups
|
static String |
PROPERTY_ORIGINAL_TABLE_HEADER_VISIBLE
|
Fields inherited from class com.jidesoft.grid.EditableTableHeader |
---|
_cellEditor, _defaultEditor, _editingColumn, _editorComp, HEADER_ROW |
Fields inherited from class com.jidesoft.grid.SortableTableHeader |
---|
PROPERTY_SHOW_SORT_ARROW |
Fields inherited from class com.jidesoft.grid.CellStyleTableHeader |
---|
_cellStyleList |
Fields inherited from class com.jidesoft.grid.DraggingTableHeader |
---|
PROPERTY_DRAGGED_COLUMN, PROPERTY_DRAGGED_DISTANCE, PROPERTY_RESIZING_COLUMN |
Fields inherited from class javax.swing.table.JTableHeader |
---|
columnModel, draggedColumn, draggedDistance, reorderingAllowed, resizingAllowed, resizingColumn, table, updateTableInRealTime |
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 java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
NestedTableHeader(JTable table)
The constructor that takes table. |
|
NestedTableHeader(TableColumnModel model)
|
Method Summary | |
---|---|
void |
addColumnGroup(TableColumnGroup group)
Adds a column group to table header. |
void |
clearColumnGroups()
Removes all column groups. |
int |
columnAtPoint(Point point)
|
JToolTip |
createToolTip()
|
int |
getActualHeaderY()
Gets the start Y of actual table header. |
String |
getActualUIClassID()
Returns a string that specifies the name of the L&F class that renders this component. |
Rectangle |
getCellRect(int row,
int column)
|
CellSpan |
getCellSpanAt(int rowIndex,
int columnIndex)
Gets the cell span of the nested table header. |
int |
getColumnCount()
|
Enumeration |
getColumnGroups(TableColumn column)
Gets an enumeration of table column groups. |
Rectangle |
getHeaderRect(int column)
|
Object |
getHeaderValueAt(int rowIndex,
int columnIndex)
Gets the header value at the specified cell. |
int |
getLevel(TableColumn column)
Gets the level of the TableColumn. |
int |
getMargin()
Gets the margin between TableColumn's. |
Object |
getParent(TableColumn column)
Gets the parent of the table column. |
int |
getRowAt(TableColumn column)
Gets the starts row index for the column. |
int |
getRowCount()
Gets the row count since it has nested table header. |
TableColumnGroup |
getTableColumnGroup(int rowIndex,
int columnIndex)
Get the corresponding TableColumnGroup in the designated row and column. |
TableColumn[] |
getTableColumnGroups()
Gets all the TableColumnGroups added to NestedtableHeader as an array. |
String |
getUIDelegateClassID()
Returns a string that specifies the name of the UIDelegate class that paints this component. |
boolean |
isMouseOnOriginalTableHeader(Point point)
Check if the mouse point is on the original table header |
boolean |
isOriginalTableHeaderVisible()
Checks if the original table header is visible. |
int |
originalColumnAtPoint(Point point)
Gets column at point disregarding the Y. |
Rectangle |
originalGetCellRect(int row,
int column)
|
void |
removeColumnGroup(TableColumnGroup group)
Removes a column group to table header. |
int |
rowAtPoint(Point p)
Returns the index of the row that point lies in. |
void |
setMargin(int margin)
Sets the margin between TableColumn's. |
void |
setOriginalTableHeaderVisible(boolean originalTableHeaderVisible)
Shows or hides the original table header visible. |
protected void |
tableModelChanged(JTable table)
This method will be called when TableModel on JTable is changed. |
Methods inherited from class com.jidesoft.grid.EditableTableHeader |
---|
cancelEditing, customizeEditorComponent, editCellAt, editCellAt, editingCanceled, getCellEditor, getCellEditor, getDefaultEditor, getEditingColumn, getEditorComponent, isClickToStartEditing, isEditing, prepareEditor, removeEditor, removeNotify, resizeAndRepaint, setCellEditor, setClickToStartEditing, setDefaultEditor, setDraggedColumn, setEditingColumn, setRolloverEnabled, stopEditing |
Methods inherited from class com.jidesoft.grid.SortableTableHeader |
---|
createSortableTableHeaderCellDecorator, createSortIcon, getSortableTableHeaderCellDecorator, isShowSortArrow, paintComponent, paintSortArrow, paintSortArrows |
Methods inherited from class com.jidesoft.grid.DraggingTableHeader |
---|
getPreferredSize, setDraggedDistance, setResizingColumn |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected Vector<TableColumn> _columnGroups
public static final String PROPERTY_ORIGINAL_TABLE_HEADER_VISIBLE
Constructor Detail |
---|
public NestedTableHeader(TableColumnModel model)
public NestedTableHeader(JTable table)
table
- the tableMethod Detail |
---|
public Rectangle getHeaderRect(int column)
getHeaderRect
in class JTableHeader
public String getActualUIClassID()
SortableTableHeader
getActualUIClassID
in class AutoFilterTableHeader
public String getUIDelegateClassID()
getUIDelegateClassID
in class AutoFilterTableHeader
protected void tableModelChanged(JTable table)
AutoFilterTableHeader
tableModelChanged
in class AutoFilterTableHeader
table
- the tablepublic TableColumn[] getTableColumnGroups()
NestedtableHeader
as an array.
public void addColumnGroup(TableColumnGroup group)
group
- TableColumnGroup to be added.getTableColumnGroups()
public void removeColumnGroup(TableColumnGroup group)
group
- TableColumnGroup to be removed.public void clearColumnGroups()
public Object getParent(TableColumn column)
column
- the TableColumn.
public int rowAtPoint(Point p)
point
lies in.
p
- the point
public Enumeration getColumnGroups(TableColumn column)
column
- the TableColumn.
public int getRowAt(TableColumn column)
column
- the TableColumn instance.
public int getLevel(TableColumn column)
column
- the TableColumn
public boolean isOriginalTableHeaderVisible()
public void setOriginalTableHeaderVisible(boolean originalTableHeaderVisible)
originalTableHeaderVisible
- true or false.public boolean isMouseOnOriginalTableHeader(Point point)
point
- mouse point
public TableColumnGroup getTableColumnGroup(int rowIndex, int columnIndex)
rowIndex
- the row indexcolumnIndex
- the column index
public int getRowCount()
public int getColumnCount()
public CellSpan getCellSpanAt(int rowIndex, int columnIndex)
rowIndex
- the row index.columnIndex
- the column index.
public Rectangle originalGetCellRect(int row, int column)
public Rectangle getCellRect(int row, int column)
public int getActualHeaderY()
CellStyleTableHeader
NestedTableHeader
and GroupTableHeader
scenarios, this method will return different value other
than 0.
getActualHeaderY
in class CellStyleTableHeader
public int columnAtPoint(Point point)
columnAtPoint
in class JTableHeader
public int originalColumnAtPoint(Point point)
CellStyleTableHeader
originalColumnAtPoint
in class CellStyleTableHeader
point
- the mouse point
public Object getHeaderValueAt(int rowIndex, int columnIndex)
rowIndex
- the row index.columnIndex
- the column index.
public int getMargin()
setMargin(int)
public void setMargin(int margin)
margin
- the marginpublic JToolTip createToolTip()
createToolTip
in class CellStyleTableHeader
|
JIDE 3.5.15 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |