java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JTable
org.autogui.swing.GuiSwingViewCollectionTable.CollectionTable
- All Implemented Interfaces:
ImageObserver
,MenuContainer
,Serializable
,EventListener
,Accessible
,CellEditorListener
,ListSelectionListener
,RowSorterListener
,TableColumnModelListener
,TableModelListener
,Scrollable
,GuiMappingContext.SourceUpdateListener
,GuiSwingView.SettingsWindowClient
,GuiSwingView.ValuePane<List<?>>
,GuiSwingPrefsSupports.PreferencesUpdateSupport
,GuiSwingTableColumnSet.TableSelectionSource
- Direct Known Subclasses:
LambdaProperty.LambdaCollectionTable
- Enclosing class:
GuiSwingViewCollectionTable
public static class GuiSwingViewCollectionTable.CollectionTable
extends JTable
implements GuiMappingContext.SourceUpdateListener, GuiSwingView.ValuePane<List<?>>, GuiSwingTableColumnSet.TableSelectionSource, GuiSwingPrefsSupports.PreferencesUpdateSupport, GuiSwingView.SettingsWindowClient
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JTable
JTable.AccessibleJTable, JTable.DropLocation, JTable.PrintMode
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
FieldsModifier and TypeFieldDescriptionprotected JToolBar
protected int
protected List
<PopupCategorized.CategorizedMenuItem> protected GuiMappingContext
protected boolean
protected boolean
protected boolean
some row-height is customized bysetRowHeight(int, int)
.protected MenuBuilder.MenuLabel
protected List
<PopupCategorized.CategorizedMenuItem> protected int
protected EditingRunner
protected SettingsWindow
protected List
<?> protected GuiSwingView.SpecifierManager
protected GuiTaskClock
Fields inherited from class javax.swing.JTable
AUTO_RESIZE_ALL_COLUMNS, AUTO_RESIZE_LAST_COLUMN, AUTO_RESIZE_NEXT_COLUMN, AUTO_RESIZE_OFF, AUTO_RESIZE_SUBSEQUENT_COLUMNS, autoCreateColumnsFromModel, autoResizeMode, cellEditor, cellSelectionEnabled, columnModel, dataModel, defaultEditorsByColumnClass, defaultRenderersByColumnClass, editingColumn, editingRow, editorComp, gridColor, preferredViewportSize, rowHeight, rowMargin, rowSelectionAllowed, selectionBackground, selectionForeground, selectionModel, showHorizontalLines, showVerticalLines, tableHeader
Fields inherited from class javax.swing.JComponent
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
accessibleContext, 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
ConstructorsConstructorDescriptionCollectionTable
(GuiMappingContext context, GuiSwingView.SpecifierManager specifierManager) -
Method Summary
Modifier and TypeMethodDescriptionvoid
changeSelection
(int[] selectedModelRowsIndices, GuiSwingTableColumnSet.TableSelectionChange change) void
changeSelectionIndices
(int[] selectedModelRowsIndices, GuiSwingTableColumnSet.TableSelectionChangeIndices change) void
changeSelectionIndicesRowAndColumns
(int[] selectedModelRowsIndices, GuiSwingTableColumnSet.TableSelectionChangeIndicesRowAndColumn change) void
changeSelectionNothing
(int[] selectedModelRowsIndices, GuiSwingTableColumnSet.TableSelectionChange change) void
changeSelectionValues
(int[] selectedModelRowsIndices, GuiSwingTableColumnSet.TableSelectionChangeValues change) int
convertColumnIndexToView
(int modelColumnIndex) protected JTableHeader
getPopup()
int
obtains an object for row-height customizingList
<?> List
<?> a typical implementation if there are no dynamic items becomes like the following code:a typical implementation becomes like the following code:List
<?> getToolTipText
(MouseEvent event) boolean
void
init()
void
initAction
(JToolBar actionToolBar, Action action) initActionToolBar
(List<Action> actions) void
void
void
void
void
void
initGrid()
void
void
initName()
void
void
void
void
void
void
void
initTableScrollPane
(JScrollPane scrollPane) void
protected boolean
boolean
void
loadSwingPreferences
(GuiPreferences prefs, GuiSwingPrefsApplyOptions options) a sub-class which wraps another value-pane should overrides the method in order to omit needless value setting.protected void
protected void
void
for each component, the method is called before refreshing in order to clear the view-clock.void
void
void
only save the component itself, not including children.void
selectionActionFinished
(boolean autoSelection, GuiSwingTableColumnSet.TableSelectionChange change) the finisher for the action: the table implements the method in order to refresh selected rows.void
the preparation for the action: the table stops editingvoid
setCellEditor
(TableCellEditor anEditor) void
setKeyStrokeString
(String keyStrokeString) set the key-stroke info.void
void
setRowHeight
(int rowHeight) void
setRowHeight
(int row, int rowHeight) void
setRowHeightByUser
(int rowHeight) setting the custom row-heightvoid
setSettingsWindow
(SettingsWindow settingsWindow) at initialization of the root-pane, the method will be called for existing sub-panes.void
setSwingViewValue
(List<?> value) update GUI display, and it does NOT update the target model value.void
setSwingViewValue
(List<?> value, GuiTaskClock clock) update if the clock is newer than the current view-clock of the pane.void
setSwingViewValueWithUpdate
(List<?> value) update the GUI display and the model.void
setSwingViewValueWithUpdate
(List<?> value, GuiTaskClock clock) update the GUI display and the model if the clock is newer than the current view-clock of the pane.void
setup related components for the table and actionssetupAfterAddingColumns
(List<Action> actions) void
for each component, at the end of the process, this method will be calledvoid
overrides for preserving custom-row-heights if e is a total refreshing: IfTableModelEvent.getLastRow()
isInteger.MAX_VALUE
, it indicates updating of all rows.void
update
(GuiMappingContext cause, Object newValue, GuiTaskClock contextClock) void
updateFromGui
(Object v, GuiTaskClock viewClock) void
update by context and refresh byObjectTableModel.refreshData()
void
update by context and refresh byObjectTableModel.refreshData()
Methods inherited from class javax.swing.JTable
addColumn, addColumnSelectionInterval, addNotify, addRowSelectionInterval, changeSelection, clearSelection, columnAdded, columnAtPoint, columnMarginChanged, columnMoved, columnRemoved, columnSelectionChanged, configureEnclosingScrollPane, convertColumnIndexToModel, convertRowIndexToModel, convertRowIndexToView, createDefaultColumnModel, createDefaultColumnsFromModel, createDefaultDataModel, createDefaultEditors, createDefaultRenderers, createDefaultSelectionModel, createScrollPaneForTable, doLayout, editCellAt, editCellAt, editingCanceled, editingStopped, getAccessibleContext, getAutoCreateColumnsFromModel, getAutoCreateRowSorter, getAutoResizeMode, getCellEditor, getCellEditor, getCellRect, getCellRenderer, getCellSelectionEnabled, getColumn, getColumnClass, getColumnCount, getColumnModel, getColumnName, getColumnSelectionAllowed, getDefaultEditor, getDefaultRenderer, getDragEnabled, getDropLocation, getDropMode, getEditingColumn, getEditingRow, getEditorComponent, getFillsViewportHeight, getGridColor, getIntercellSpacing, getModel, getPreferredScrollableViewportSize, getPrintable, getRowCount, getRowHeight, getRowHeight, getRowMargin, getRowSelectionAllowed, getRowSorter, getScrollableBlockIncrement, getScrollableTracksViewportHeight, getScrollableTracksViewportWidth, getScrollableUnitIncrement, getSelectedColumn, getSelectedColumnCount, getSelectedColumns, getSelectedRow, getSelectedRowCount, getSelectedRows, getSelectionBackground, getSelectionForeground, getSelectionModel, getShowHorizontalLines, getShowVerticalLines, getSurrendersFocusOnKeystroke, getTableHeader, getUI, getUIClassID, getUpdateSelectionOnSort, getValueAt, initializeLocalVars, isCellEditable, isCellSelected, isColumnSelected, isEditing, isRowSelected, moveColumn, paramString, prepareEditor, prepareRenderer, print, print, print, print, print, processKeyBinding, removeColumn, removeColumnSelectionInterval, removeEditor, removeNotify, removeRowSelectionInterval, resizeAndRepaint, rowAtPoint, selectAll, setAutoCreateColumnsFromModel, setAutoCreateRowSorter, setAutoResizeMode, setCellSelectionEnabled, setColumnModel, setColumnSelectionAllowed, setColumnSelectionInterval, setDefaultEditor, setDefaultRenderer, setDragEnabled, setDropMode, setEditingColumn, setEditingRow, setFillsViewportHeight, setGridColor, setIntercellSpacing, setModel, setPreferredScrollableViewportSize, setRowMargin, setRowSelectionAllowed, setRowSelectionInterval, setRowSorter, setSelectionBackground, setSelectionForeground, setSelectionMode, setSelectionModel, setShowGrid, setShowHorizontalLines, setShowVerticalLines, setSurrendersFocusOnKeystroke, setTableHeader, setUI, setUpdateSelectionOnSort, setValueAt, sizeColumnsToFit, sizeColumnsToFit, sorterChanged, unconfigureEnclosingScrollPane, updateUI, valueChanged
Methods inherited from class javax.swing.JComponent
addAncestorListener, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingOrigin, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setMixingCutoutShape, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.autogui.swing.GuiSwingView.ValuePane
addSwingEditFinishHandler, asSwingViewComponent, executeContextTask, getActionByContext, getActionByName, getChildByName, getDescendantActionByContext, getDescendantByContext, getDescendantByValue, getDescendantByValueIf, getPrefsJsonSupported, getSwingFocusKeyStroke, isSwingCurrentValueSupported, isSwingEditable, loadSwingPreferences, refreshByContext, requestSwingViewFocus, setPrefsJsonSupported, setSwingViewHistoryValue, setSwingViewValueForTable, wrapSwingNamed, wrapSwingPane, wrapSwingProperty, wrapSwingScrollPane
-
Field Details
-
context
-
specifierManager
-
source
-
popup
-
actions
-
autoSelectionActions
-
autoSelectionDepth
protected int autoSelectionDepth -
selectionRunner
-
preferencesUpdater
-
lastSelectionActionIndices
-
selectionSourceForRowIndices
-
selectionSourceForRowAndColumnIndices
protected GuiSwingViewCollectionTable.TableSelectionSourceForIndices selectionSourceForRowAndColumnIndices -
popupColumnHeader
-
columnHeaderMenuItems
-
infoLabel
-
actionToolBar
-
viewClock
-
settingsWindow
-
customHighlighting
protected boolean customHighlighting -
customRowHeightByUser
protected boolean customRowHeightByUser- Since:
- 1.3
-
rowHeightByProgram
protected int rowHeightByProgram- Since:
- 1.3
-
customRowHeightIndividual
protected boolean customRowHeightIndividualsome row-height is customized bysetRowHeight(int, int)
. cleared bysetRowHeight(int)
- Since:
- 1.6
-
rowHeightSetAction
- Since:
- 1.6
-
-
Constructor Details
-
CollectionTable
-
-
Method Details
-
init
public void init() -
initColor
public void initColor() -
initName
public void initName() -
initModel
public void initModel() -
initContextUpdate
public void initContextUpdate() -
initPopup
public void initPopup() -
initGrid
public void initGrid() -
initSelection
public void initSelection() -
initSelectionSource
public void initSelectionSource() -
initSelectionClear
public void initSelectionClear() -
initRowHeight
public void initRowHeight() -
initValue
public void initValue() -
initPreferencesUpdater
public void initPreferencesUpdater() -
initDragDrop
public void initDragDrop() -
initFocus
public void initFocus() -
initAfter
public void initAfter() -
getSwingStaticMenuItems
Description copied from interface:GuiSwingView.ValuePane
a typical implementation becomes like the following code:if (menuItems == null) { menuItems =
PopupCategorized
.getMenuItems(actions, menus); } return menuItems;the method returns original menu items for the pane. so, if a wrapper pane has a wrapped sub-pane added as a child component, it should not include items of the wrapped sub-pane.
- Specified by:
getSwingStaticMenuItems
in interfaceGuiSwingView.ValuePane<List<?>>
- Returns:
- a list of actions (or menu-components) statically determined, that should be always same instances
-
getPopup
-
setupAfterAddingColumns
-
setupAfterAddingColumns
public void setupAfterAddingColumns()setup related components for the table and actions- Since:
- 1.1
-
initTableScrollPane
-
initTableScrollPane
-
isAutoResizeOff
protected boolean isAutoResizeOff() -
initActionToolBar
-
runListSelection
-
runAutoSelectionActions
-
initAction
-
setSettingsWindow
Description copied from interface:GuiSwingView.SettingsWindowClient
at initialization of the root-pane, the method will be called for existing sub-panes. a dynamically created view needs to be manually set by those panes.- Specified by:
setSettingsWindow
in interfaceGuiSwingView.SettingsWindowClient
- Parameters:
settingsWindow
- a settings-window from the root-pane, which will be disposed at closing of the main window
-
getSettingsWindow
- Specified by:
getSettingsWindow
in interfaceGuiSwingView.SettingsWindowClient
-
getActions
-
getSwingMenuBuilder
Description copied from interface:GuiSwingView.ValuePane
a typical implementation if there are no dynamic items becomes like the following code:if (popup == null) { popup = new
PopupExtension
(this, newPopupCategorized
(this::getSwingStaticMenuItems)); } return popup.getMenuBuilder();- Specified by:
getSwingMenuBuilder
in interfaceGuiSwingView.ValuePane<List<?>>
- Returns:
- a menu builder
-
getObjectTableModel
-
getSource
-
getSelectionSourceForRowAndColumnIndices
public GuiSwingViewCollectionTable.TableSelectionSourceForIndices getSelectionSourceForRowAndColumnIndices() -
getSelectionSourceForRowIndices
-
update
- Specified by:
update
in interfaceGuiMappingContext.SourceUpdateListener
-
getSwingViewValue
- Specified by:
getSwingViewValue
in interfaceGuiSwingView.ValuePane<List<?>>
- Returns:
- basically, the source value of the context, held by the component without touching the context.
-
setSwingViewValue
Description copied from interface:GuiSwingView.ValuePane
update GUI display, and it does NOT update the target model value. processed under the event thread. also increment the view-clock.- Specified by:
setSwingViewValue
in interfaceGuiSwingView.ValuePane<List<?>>
- Parameters:
value
- the new value
-
setSwingViewValueWithUpdate
Description copied from interface:GuiSwingView.ValuePane
update the GUI display and the model. processed under the event thread. also increment the view-clock- Specified by:
setSwingViewValueWithUpdate
in interfaceGuiSwingView.ValuePane<List<?>>
- Parameters:
value
- the new value
-
setSwingViewValue
Description copied from interface:GuiSwingView.ValuePane
update if the clock is newer than the current view-clock of the pane. the view-clock becomes the given clock. Note: instead,GuiSwingView.ValuePane.setSwingViewValue(Object)
increments the current clock- Specified by:
setSwingViewValue
in interfaceGuiSwingView.ValuePane<List<?>>
- Parameters:
value
- the new valueclock
- the clock of the value: if the clock is newer than the current view-clock of the pane, it can update
-
setSwingViewValueWithUpdate
Description copied from interface:GuiSwingView.ValuePane
update the GUI display and the model if the clock is newer than the current view-clock of the pane. the view-clock becomes the given clock.- Specified by:
setSwingViewValueWithUpdate
in interfaceGuiSwingView.ValuePane<List<?>>
- Parameters:
value
- the new valueclock
- the clock of the value
-
updateFromGui
-
setPreferencesUpdater
- Specified by:
setPreferencesUpdater
in interfaceGuiSwingPrefsSupports.PreferencesUpdateSupport
-
shutdownSwingView
public void shutdownSwingView()Description copied from interface:GuiSwingView.ValuePane
for each component, at the end of the process, this method will be called- Specified by:
shutdownSwingView
in interfaceGuiSwingView.ValuePane<List<?>>
-
prepareForRefresh
public void prepareForRefresh()Description copied from interface:GuiSwingView.ValuePane
for each component, the method is called before refreshing in order to clear the view-clock.- Specified by:
prepareForRefresh
in interfaceGuiSwingView.ValuePane<List<?>>
-
getActionToolBar
-
getTargetName
- Specified by:
getTargetName
in interfaceGuiSwingTableColumnSet.TableSelectionSource
-
isSelectionEmpty
public boolean isSelectionEmpty()- Specified by:
isSelectionEmpty
in interfaceGuiSwingTableColumnSet.TableSelectionSource
-
getSelectedItems
- Specified by:
getSelectedItems
in interfaceGuiSwingTableColumnSet.TableSelectionSource
-
selectionActionFinished
public void selectionActionFinished(boolean autoSelection, GuiSwingTableColumnSet.TableSelectionChange change) Description copied from interface:GuiSwingTableColumnSet.TableSelectionSource
the finisher for the action: the table implements the method in order to refresh selected rows. However, naive executions of the action by list selection changes will cause infinite loop. To avoid this, an impl. of the method needs to check the flag and avoid handling list selection events caused by the method.- Specified by:
selectionActionFinished
in interfaceGuiSwingTableColumnSet.TableSelectionSource
- Parameters:
autoSelection
- true if the action is automatically executed by selection changeschange
- specification of selection changes
-
changeSelection
public void changeSelection(int[] selectedModelRowsIndices, GuiSwingTableColumnSet.TableSelectionChange change) -
changeSelectionNothing
public void changeSelectionNothing(int[] selectedModelRowsIndices, GuiSwingTableColumnSet.TableSelectionChange change) -
changeSelectionIndices
public void changeSelectionIndices(int[] selectedModelRowsIndices, GuiSwingTableColumnSet.TableSelectionChangeIndices change) -
changeSelectionValues
public void changeSelectionValues(int[] selectedModelRowsIndices, GuiSwingTableColumnSet.TableSelectionChangeValues change) -
changeSelectionIndicesRowAndColumns
public void changeSelectionIndicesRowAndColumns(int[] selectedModelRowsIndices, GuiSwingTableColumnSet.TableSelectionChangeIndicesRowAndColumn change) -
getSwingViewContext
- Specified by:
getSwingViewContext
in interfaceGuiSwingView.ValuePane<List<?>>
-
loadSwingPreferences
Description copied from interface:GuiSwingView.ValuePane
a sub-class which wraps another value-pane should overrides the method in order to omit needless value setting. it can useGuiSwingView.loadPreferencesDefault(JComponent, GuiPreferences)
- Specified by:
loadSwingPreferences
in interfaceGuiSwingView.ValuePane<List<?>>
- Parameters:
prefs
- target prefs or ancestor of the target; actual target can be obtained byGuiPreferences.getDescendant(GuiMappingContext)
options
- options for applying
-
saveSwingPreferences
Description copied from interface:GuiSwingView.ValuePane
only save the component itself, not including children. it can useGuiSwingView.savePreferencesDefault(JComponent, GuiPreferences)
- Specified by:
saveSwingPreferences
in interfaceGuiSwingView.ValuePane<List<?>>
- Parameters:
prefs
- target prefs or ancestor of the target; actual target can be obtained byGuiPreferences.getDescendant(GuiMappingContext)
-
paintComponent
- Overrides:
paintComponent
in classJComponent
-
paintSelectedRows
-
getSpecifier
- Specified by:
getSpecifier
in interfaceGuiSwingView.ValuePane<List<?>>
- Returns:
- the specifier for the context value, typically obtained from
GuiSwingView.SpecifierManager
-
getRowSpecifier
-
setKeyStrokeString
Description copied from interface:GuiSwingView.ValuePane
set the key-stroke info. to the pane as a guide- Specified by:
setKeyStrokeString
in interfaceGuiSwingView.ValuePane<List<?>>
- Parameters:
keyStrokeString
- the key stroke info to be set.
-
getColumnHeaderMenuItems
-
convertColumnIndexToView
public int convertColumnIndexToView(int modelColumnIndex) - Overrides:
convertColumnIndexToView
in classJTable
-
updateSwingViewSource
public void updateSwingViewSource()update by context and refresh byObjectTableModel.refreshData()
- Specified by:
updateSwingViewSource
in interfaceGuiSwingView.ValuePane<List<?>>
- Since:
- 1.1
-
updateSwingViewSourceFromRoot
public void updateSwingViewSourceFromRoot()update by context and refresh byObjectTableModel.refreshData()
- Specified by:
updateSwingViewSourceFromRoot
in interfaceGuiSwingView.ValuePane<List<?>>
- Since:
- 1.1
-
setCellEditor
- Overrides:
setCellEditor
in classJTable
-
selectionActionPrepare
public void selectionActionPrepare()Description copied from interface:GuiSwingTableColumnSet.TableSelectionSource
the preparation for the action: the table stops editing- Specified by:
selectionActionPrepare
in interfaceGuiSwingTableColumnSet.TableSelectionSource
-
setRowHeight
public void setRowHeight(int rowHeight) - Overrides:
setRowHeight
in classJTable
-
setRowHeightByUser
public void setRowHeightByUser(int rowHeight) setting the custom row-height- Parameters:
rowHeight
- the new row-height- Since:
- 1.3
-
setRowHeight
public void setRowHeight(int row, int rowHeight) - Overrides:
setRowHeight
in classJTable
-
hasCustomRowHeightByUser
public boolean hasCustomRowHeightByUser()- Returns:
- true if it has the value set by
setRowHeightByUser(int)
- Since:
- 1.3
-
getRowHeightByProgram
public int getRowHeightByProgram()- Returns:
- the last row-height set by
setRowHeight(int)
- Since:
- 1.3
-
getToolTipText
- Overrides:
getToolTipText
in classJTable
-
createDefaultTableHeader
- Overrides:
createDefaultTableHeader
in classJTable
-
tableChanged
overrides for preserving custom-row-heights if e is a total refreshing: IfTableModelEvent.getLastRow()
isInteger.MAX_VALUE
, it indicates updating of all rows. Then, the default impl. ofJTable
clears custom all-row-heights set bysetRowHeight(int, int)
. This causes unintended row-heights expansion by re-painting after the method. So, the overriding impl. saves before super call, and resets the saved values before re-painting.- Specified by:
tableChanged
in interfaceTableModelListener
- Overrides:
tableChanged
in classJTable
- Parameters:
e
- a model-event
-
getRowHeightSetAction
obtains an object for row-height customizing- Returns:
- the action instance associated to the table
- Since:
- 1.6
-