public abstract class TableUIBridge extends TableUI
Modifier and Type | Class and Description |
---|---|
protected static class |
TableUIBridge.Actions
The type Actions.
|
class |
TableUIBridge.FocusHandler
This class should be treated as a "protected" inner class.
|
protected class |
TableUIBridge.Handler
The type Handler.
|
class |
TableUIBridge.KeyHandler
This class should be treated as a "protected" inner class.
|
class |
TableUIBridge.MouseInputHandler
This class should be treated as a "protected" inner class.
|
Modifier and Type | Field and Description |
---|---|
protected static StringBuilder |
BASELINE_COMPONENT_KEY
The constant BASELINE_COMPONENT_KEY.
|
protected static TransferHandler |
defaultTransferHandler
The constant defaultTransferHandler.
|
protected FocusListener |
focusListener
FocusListener that are attached to the JTable . |
protected TableUIBridge.Handler |
handler
The Handler.
|
protected boolean |
isFileList
Local cache of Table's client property DarkTableUI.KEY_IS_FILE_LIST
|
protected KeyListener |
keyListener
KeyListener that are attached to the JTable . |
protected MouseInputListener |
mouseInputListener
MouseInputListener that are attached to the JTable . |
protected CellRendererPane |
rendererPane
The instance of
CellRendererPane . |
protected JTable |
table
The instance of
JTable . |
Constructor and Description |
---|
TableUIBridge() |
Modifier and Type | Method and Description |
---|---|
protected FocusListener |
createFocusListener()
Creates the focus listener for handling keyboard navigation in the
JTable . |
protected KeyListener |
createKeyListener()
Creates the key listener for handling keyboard navigation in the
JTable . |
protected MouseInputListener |
createMouseInputListener()
Creates the mouse listener for the
JTable . |
protected Dimension |
createTableSize(long width)
Create table size dimension.
|
static ComponentUI |
createUI(JComponent c)
Returns a new instance of
BasicTableUI . |
protected Rectangle |
extendRect(Rectangle rect,
boolean horizontal)
Extend rect rectangle.
|
protected static int |
getAdjustedLead(JTable table,
boolean row)
Gets adjusted lead.
|
protected static int |
getAdjustedLead(JTable table,
boolean row,
ListSelectionModel model)
Gets adjusted lead.
|
int |
getBaseline(JComponent c,
int width,
int height)
Returns the baseline.
|
Component.BaselineResizeBehavior |
getBaselineResizeBehavior(JComponent c)
Returns an enum indicating how the baseline of the component changes as the size changes.
|
protected TableUIBridge.Handler |
getHandler()
Gets handler.
|
protected Rectangle |
getHDropLineRect(JTable.DropLocation loc)
Gets h drop line rect.
|
Dimension |
getMaximumSize(JComponent c)
Return the maximum size of the table.
|
Dimension |
getMinimumSize(JComponent c)
Return the minimum size of the table.
|
Dimension |
getPreferredSize(JComponent c)
Return the preferred size of the table.
|
protected Rectangle |
getVDropLineRect(JTable.DropLocation loc)
Gets v drop line rect.
|
protected void |
installDefaults()
Initialize JTable properties, e.g.
|
protected void |
installDefaults2()
Install defaults 2.
|
protected void |
installKeyboardActions()
Register all keyboard actions on the JTable.
|
protected void |
installListeners()
Attaches listeners to the JTable.
|
void |
installUI(JComponent c) |
static void |
loadActionMap(LazyActionMap map)
Load action map.
|
void |
paint(Graphics g,
JComponent c)
Paint a representation of the
table instance that was set in installUI(). |
protected void |
paintCell(Graphics g,
Rectangle cellRect,
int row,
int column)
Paint cell.
|
protected void |
paintCells(Graphics g,
int rMin,
int rMax,
int cMin,
int cMax)
Paint cells.
|
protected void |
paintDraggedArea(Graphics g,
int rMin,
int rMax,
TableColumn draggedColumn,
int distance)
Paint dragged area.
|
protected void |
paintDropLines(Graphics g)
Paint drop lines.
|
protected void |
paintGrid(Graphics g,
int rMin,
int rMax,
int cMin,
int cMax)
Paint grid.
|
protected boolean |
pointOutsidePrefSize(int row,
int column,
Point p)
Point outside pref size boolean.
|
protected void |
uninstallDefaults()
Uninstalls default properties.
|
protected void |
uninstallKeyboardActions()
Unregisters keyboard actions.
|
protected void |
uninstallListeners()
Unregisters listeners.
|
void |
uninstallUI(JComponent c) |
protected int |
viewIndexForColumn(TableColumn aColumn)
View index for column int.
|
contains, getAccessibleChild, getAccessibleChildrenCount, update
protected static final StringBuilder BASELINE_COMPONENT_KEY
protected static final TransferHandler defaultTransferHandler
protected JTable table
JTable
.protected CellRendererPane rendererPane
CellRendererPane
.protected KeyListener keyListener
KeyListener
that are attached to the JTable
.protected FocusListener focusListener
FocusListener
that are attached to the JTable
.protected MouseInputListener mouseInputListener
MouseInputListener
that are attached to the JTable
.protected TableUIBridge.Handler handler
protected boolean isFileList
public static ComponentUI createUI(JComponent c)
BasicTableUI
.c
- a componentBasicTableUI
public static void loadActionMap(LazyActionMap map)
map
- the mapprotected static int getAdjustedLead(JTable table, boolean row)
table
- the tablerow
- the rowprotected static int getAdjustedLead(JTable table, boolean row, ListSelectionModel model)
table
- the tablerow
- the rowmodel
- the modelprotected boolean pointOutsidePrefSize(int row, int column, Point p)
row
- the rowcolumn
- the columnp
- the ppublic void installUI(JComponent c)
installUI
in class ComponentUI
protected void installDefaults()
#installUI
protected void installDefaults2()
protected void installListeners()
protected void installKeyboardActions()
protected FocusListener createFocusListener()
JTable
.JTable
protected KeyListener createKeyListener()
JTable
.JTable
protected MouseInputListener createMouseInputListener()
JTable
.JTable
protected TableUIBridge.Handler getHandler()
public void uninstallUI(JComponent c)
uninstallUI
in class ComponentUI
protected void uninstallDefaults()
protected void uninstallListeners()
protected void uninstallKeyboardActions()
public void paint(Graphics g, JComponent c)
table
instance that was set in installUI().paint
in class ComponentUI
public Dimension getPreferredSize(JComponent c)
getPreferredSize
in class ComponentUI
public Dimension getMinimumSize(JComponent c)
getMinimumSize
in class ComponentUI
public Dimension getMaximumSize(JComponent c)
getMaximumSize
in class ComponentUI
public int getBaseline(JComponent c, int width, int height)
getBaseline
in class ComponentUI
NullPointerException
IllegalArgumentException
JComponent.getBaseline(int, int)
public Component.BaselineResizeBehavior getBaselineResizeBehavior(JComponent c)
getBaselineResizeBehavior
in class ComponentUI
NullPointerException
JComponent.getBaseline(int, int)
protected Dimension createTableSize(long width)
width
- the widthprotected void paintDropLines(Graphics g)
g
- the gprotected Rectangle getHDropLineRect(JTable.DropLocation loc)
loc
- the locprotected Rectangle extendRect(Rectangle rect, boolean horizontal)
rect
- the recthorizontal
- the horizontalprotected Rectangle getVDropLineRect(JTable.DropLocation loc)
loc
- the locprotected void paintGrid(Graphics g, int rMin, int rMax, int cMin, int cMax)
g
- the grMin
- the r minrMax
- the r maxcMin
- the c mincMax
- the c maxprotected void paintCells(Graphics g, int rMin, int rMax, int cMin, int cMax)
g
- the grMin
- the r minrMax
- the r maxcMin
- the c mincMax
- the c maxprotected void paintCell(Graphics g, Rectangle cellRect, int row, int column)
g
- the gcellRect
- the cell rectrow
- the rowcolumn
- the columnprotected void paintDraggedArea(Graphics g, int rMin, int rMax, TableColumn draggedColumn, int distance)
g
- the grMin
- the r minrMax
- the r maxdraggedColumn
- the dragged columndistance
- the distanceprotected int viewIndexForColumn(TableColumn aColumn)
aColumn
- the a column