Class GuiSwingTableColumnString.MultilineColumnStringViewPane
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
org.autogui.swing.util.TextCellRenderer<String>
org.autogui.swing.table.GuiSwingTableColumnString.MultilineColumnStringViewPane
- All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, ListCellRenderer<String>, TableCellRenderer, GuiSwingElement.FeatureCollection, GuiSwingFeature, GuiSwingView.ValuePane<String>, ObjectTableColumn.PopupMenuBuilderSource, ObjectTableColumn.PopupMenuBuilderSourceForHeader, ObjectTableColumnValue.ObjectTableColumnCellView, ObjectTableColumnValue.ObjectTableColumnValueRenderer
- Enclosing class:
GuiSwingTableColumnString
public static class GuiSwingTableColumnString.MultilineColumnStringViewPane
extends TextCellRenderer<String>
implements GuiSwingView.ValuePane<String>, ObjectTableColumn.PopupMenuBuilderSource, ObjectTableColumnValue.ObjectTableColumnCellView, ObjectTableColumn.PopupMenuBuilderSourceForHeader, ObjectTableColumnValue.ObjectTableColumnValueRenderer
custom text renderer for multiline strings.
the TextComponent based view seems not suitable for cell-rendering,
because of emoji caching mechanism.
As my obserbation, the Swing TextComponent constrcuts internal caches for rendering emojis when string contents are changed.
And frequent changing of the contents causes slowdown for rending table cells.
- Since:
- 1.9
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class TextCellRenderer
TextCellRenderer.LineInfo, TextCellRenderer.LineInfoMatch, TextCellRenderer.LineProcessor, TextCellRenderer.LineProcessorLineInfoModifier and TypeClassDescriptionstatic classa line holdingAttributedStringstatic classfocusing information for a matched pattern positionstatic interfacethe line process functional interfaceclassconcurete impl.Nested classes/interfaces inherited from class JPanel
JPanel.AccessibleJPanelNested classes/interfaces inherited from class JComponent
JComponent.AccessibleJComponentNested classes/interfaces inherited from class Container
Container.AccessibleAWTContainerNested classes/interfaces inherited from class Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategyNested classes/interfaces inherited from interface GuiSwingFeature
GuiSwingFeature.TraversalOption, GuiSwingFeature.TraversalPredicate, GuiSwingFeature.TraversalPredicateOnce, GuiSwingFeature.TraversalPredicateOnceContext, GuiSwingFeature.VisitorModifier and TypeInterfaceDescriptionstatic enumstatic interfacestatic classstatic classstatic class -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected GuiMappingContextprotected MenuBuilder.MenuLabelprotected List<PopupCategorized.CategorizedMenuItem> protected ObjectTableColumnprotected PopupExtensionprotected GuiSwingView.SpecifierManagerFields inherited from class TextCellRenderer
baseHeight, baseWidth, findPattern, findText, forMouseEvents, lastMatch, lines, maxWidth, originalBackground, selected, selectionBackground, selectionEnd, selectionForeground, selectionStart, testImage, text, textToBackToColor, valueModifier and TypeFieldDescriptionprotected floatprotected floatprotected Patternprotected Stringprotected booleanprotected TextCellRenderer.LineInfoMatchprotected List<TextCellRenderer.LineInfo> protected intprotected Colorprotected booleanprotected Colorprotected intprotected Colorprotected intprotected BufferedImageprotected Stringprotected StringFields inherited from class JComponent
listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOWFields inherited from class Component
accessibleContext, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENTFields inherited from interface ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH -
Constructor Summary
ConstructorsConstructorDescriptionMultilineColumnStringViewPane(GuiMappingContext context, GuiSwingView.SpecifierManager specifierManager) -
Method Summary
Modifier and TypeMethodDescriptionvoidprotected TextLayoutcreateLayoutForPaintOrLayout(boolean paint, TextCellRenderer.LineInfo line, FontRenderContext frc, Color foregroundColor, Color backgroundColor, Color selectionTextColor, Color selectionColor) called fromTextCellRenderer.paintOrLayoutComponentLines(Graphics, boolean)and obtains a text-layout object for the linegetHeaderMenuItems(JTable table) getMenuBuilder(JTable table) a typical implementation if there are no dynamic items becomes like the following code:a typical implementation becomes like the following code:List<?> It returns a list of sub-nodes of the node.getTableCellRendererComponent(JTable tableNullable, Object value, boolean isSelected, boolean hasFocus, int row, int column) voidvoidsetOwnerColumn(ObjectTableColumn ownerColumn) voidsetSwingViewValue(String value) update GUI display, and it does NOT update the target model value.voidsetSwingViewValue(String value, GuiTaskClock clock) update if the clock is newer than the current view-clock of the pane.voidupdate the GUI display and the model.voidsetSwingViewValueWithUpdate(String value, GuiTaskClock clock) update the GUI display and the model if the clock is newer than the current view-clock of the pane.Methods inherited from class TextCellRenderer
buildLines, buildSize, clearSelectionRange, createBorder, createBorder, createCellTableBorderOuter, createLine, findTextForComposition, format, formatPreProcess, getBaseSize, getBorderSize, getCellBackground, getFindPattern, getFocusNextFound, getFocusNextFoundForComposition, getGridColor, getIndex, getLineFindColor, getLineFindMatchColor, getLines, getListCellRendererComponent, getSelectedTextForComposition, getSelectionBackground, getSelectionForeground, getText, getTextSelection, getValue, initBorder, initColor, isCellTableEnd, isLastMatch, isValueSame, mouseUpdateForComposition, paintBackgroundColor, paintCellSelection, paintComponent, paintLineFinds, paintLineSelection, paintOrLayoutComponentLines, paintRowsBorderSelection, paintSetUpGraphics, paintStartX, setBackground, setCellBorderDefault, setCellDefaultProperties, setCellListColor, setCellListColorDropTarget, setCellTableBorder, setCellTableBorderWithMargin, setCellTableColor, setCellTableColorDropTarget, setCellTableMargin, setDefaultAttributes, setFindHighlights, setProperty, setProperty, setSelectionBackground, setSelectionForeground, setSelectionFromValue, setSelectionRange, setTableCellSelection, setValue, setValueForComposition, splitLines, updateFindPattern, updateFindPattern, updateFindPatternForComposition, wrapBorderModifier and TypeMethodDescriptionintbuildLines(String text, List<TextCellRenderer.LineInfo> lines) float[]multiply maxWidth set byTextCellRenderer.buildFromValue()and size of lines by base char size (TextCellRenderer.getBaseSize()) , and border size byTextCellRenderer.getBorderSize()voidstatic BordercreateBorder(int top, int left, int bottom, int right) the sizes of the border will be scaled; if non 0 size is specified, the minimum becomes 1.static BordercreateBorder(int top, int left, int bottom, int right, Color background) the sizes of the border will be scaled; if non 0 size is specified, the minimum becomes 1.static BordercreateCellTableBorderOuter(JTable table, int column, Color color) -------------------------------- | matte(color) top=1, left=(2 or 0), right=(2 or 0), bottom=2 //changed by the column index | [cell] | ---------------------------------------createLine(TextCellRenderer.LineInfo prevLine, int lineIndex, int start, String line) create a line-infostatic <V> intfindTextForComposition(V value, String findKeyword, TextCellRenderer<V>... rs) formatPreProcess(String line) remove tabs from the line; for avoiding displaying tofu by AttributedStringfloat[]int[]static ColorgetCellBackground(JComponent component, boolean isTable, int row) getFocusNextFound(String value, Object prevIndex, boolean forward) focus next matched range and return it.static <V> ObjectgetFocusNextFoundForComposition(V value, Object prevIndex, boolean forward, TextCellRenderer<V>... rs) static ColorgetGridColor(Color background) modify the background color for grid-separator: a bright color becomes darker, a dark color becomes brighterintgetLines()getListCellRendererComponent(JList<? extends String> list, String value, int index, boolean isSelected, boolean cellHasFocus) static <V> StringgetSelectedTextForComposition(V value, boolean entireText, Map<TextCellRenderer<?>, int[]> rangesOpt, TextCellRenderer<V>... rs) getText()getValue()protected voidprotected voidstatic booleanisCellTableEnd(JTable table, int column, boolean left) booleanisLastMatch(int lineIndex, int rangeIndex) booleanisValueSame(String value, boolean forMouseEvents) static <V> voidmouseUpdateForComposition(V value, Map<TextCellRenderer<?>, int[]> ranges, boolean pressInit, Component pointComponent, Point point, TextCellRenderer<V>... rs) change selection range by mouse pressing, dragging or releasing.protected ColorvoidpaintCellSelection(Graphics g, Color selectionColor) protected voidvoidpaintLineFinds(Graphics2D g2, TextCellRenderer.LineInfo line, TextLayout l, int lineIndex, Color findColor, Color findMatchColor, float lineX) voidpaintLineSelection(Graphics2D g2, TextCellRenderer.LineInfo line, TextLayout l, Color selectionColor, float lineX) protected float[]paintOrLayoutComponentLines(Graphics g, boolean paint) static voidpaintRowsBorderSelection(JTable table, Graphics2D g2) draw additional round highlighting rectangles for selected rows.voidfloatpaintStartX(int lineIndex, TextCellRenderer.LineInfo prev, float prevX, TextCellRenderer.LineInfo line, TextLayout l, FontRenderContext frc) voidsetBackground(Color bg) static voidsetCellBorderDefault(boolean isTable, JComponent cell, boolean isSelected, boolean hasFocus) the fallback impl.static voidsetCellDefaultProperties(JComponent cellComponent) setting properties for renderersstatic voidsetCellListColor(JList<?> list, JComponent component, boolean isSelected, boolean hasFocus, int row) static booleansetCellListColorDropTarget(JList<?> list, JComponent component, int row) static booleansetCellTableBorder(JTable table, JComponent cell, boolean isSelected, boolean hasFocus, int row, int column) the method totally replacing the border with a new one when it returns true.static voidsetCellTableBorderWithMargin(JTable table, JComponent cell, boolean isSelected, boolean hasFocus, int row, int column) ---------------------------- | matte(alternativeColor) top=1, left=(2 or 0), right=(2 or 0), bottom=2 | matte(cell.background) top=1, left=10, right=5, bottom=1 | empty top=10, left=10, right=10, bottom=5 | [cell]static voidsetCellTableColor(JTable table, JComponent component, boolean isSelected, boolean hasFocus, int row, int column) static booleansetCellTableColorDropTarget(JTable table, JComponent component, int row, int column) static voidsetCellTableMargin(JComponent cell) ------------------------ | existing-border | empty top=7, left=8, right=8, bottom=8 | [cell]protected voidsetDefaultAttributes(AttributedString a, int len) intconstructs find-ranges for each line matched by findPattern.voidsetProperty(JList<?> list) voidsetProperty(JTable list) voidsetSelectionBackground(Color selectionBackground) voidsetSelectionForeground(Color selectionForeground) voidsetSelectionFromValue(String value) in the class, just callTextCellRenderer.setFindHighlights()voidsetSelectionRange(int from, int to) protected booleansetTableCellSelection(boolean isSelected, int row) set the selection flag, called fromTextCellRenderer.getTableCellRendererComponent(JTable, Object, boolean, boolean, int, int)booleanstatic <V> voidsetValueForComposition(V value, Map<TextCellRenderer<?>, int[]> rangesOpt, boolean forMouseEvents, TextCellRenderer<V>... rs) voidsplitLines(String text, TextCellRenderer.LineProcessor lineProcessor) the utility method for splitting text by newlinesbooleanupdateFindPattern(String findKeyword) update findText and findPatternbooleanupdateFindPattern(Pattern newPattern) update findPattern.static <V> booleanupdateFindPatternForComposition(String findKeyword, TextCellRenderer<V>... rs) static voidwrapBorder(JComponent component, Border border, boolean inside) Methods inherited from class JPanel
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUIMethods inherited from class JComponent
addAncestorListener, addNotify, 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, 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, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, updateMethods inherited from class Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, 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, validateTreeMethods inherited from class 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, transferFocusUpCycleMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface GuiSwingFeature
addSwingEditFinishHandler, executeContextTask, getPrefsJsonSupported, isSwingEditable, loadSwingPreferences, prepareForRefresh, refreshByContext, setKeyStrokeString, setPrefsJsonSupported, shutdownSwingView, updateSwingViewSource, updateSwingViewSourceFromRootModifier and TypeMethodDescriptiondefault voidaddSwingEditFinishHandler(Runnable eventHandler) the method is used for table cell-editors, in order to observe the completion of editing.default <RetType> GuiSwingTaskRunner.ContextTaskResult<RetType> executeContextTask(Supplier<RetType> task, Consumer<GuiSwingTaskRunner.ContextTaskResult<RetType>> afterTask) default Objectdefault booleandefault voidthe convient method for loading preferences withGuiSwingPrefsApplyOptions.APPLY_OPTIONS_DEFAULT.default voidfor each component, the method is called before refreshing in order to clear the view-clock.default voidprepare, clear and update via the contextdefault voidsetKeyStrokeString(String keyStrokeString) set the key-stroke info.default voidsetPrefsJsonSupported(Object json) default voidfor each component, at the end of the process, this method will be calleddefault voidnotifies property update to the component.default voidnotifies property update to the component and enclosing other components.Methods inherited from interface GuiSwingView.ValuePane
asSwingViewComponent, getSwingFocusKeyStroke, getSwingViewSubNodesSameDisplay, isSwingCurrentValueSupported, loadSwingPreferences, requestSwingViewFocus, saveSwingPreferences, setSwingViewHistoryValue, setSwingViewValueForTable, wrapSwingNamed, wrapSwingPane, wrapSwingProperty, wrapSwingScrollPaneModifier and TypeMethodDescriptiondefault JComponentdefault KeyStrokedefault List<?> default booleandefault voidloadSwingPreferences(GuiPreferences prefs, GuiSwingPrefsApplyOptions options) a sub-class which wraps another value-pane should overrides the method in order to omit needless value setting.default voiddefault voidonly save the component itself, not including children.default voidsetSwingViewHistoryValue(Object value) called from a value history menu.default voidsetSwingViewValueForTable(JTable table, Object value, int row, int column) update GUI display as a table-cell.wrapSwingScrollPane(boolean verticalAlways, boolean horizontalAlways) Methods inherited from interface ObjectTableColumnValue.ObjectTableColumnCellView
isSkippingSet, setForComponentModifier and TypeMethodDescriptiondefault booleandefault <CompType> voidsetForComponent(Class<CompType> componentType, Consumer<CompType> setter)
-
Field Details
-
context
-
specifierManager
-
popup
-
ownerColumn
-
infoLabel
-
-
Constructor Details
-
MultilineColumnStringViewPane
public MultilineColumnStringViewPane(GuiMappingContext context, GuiSwingView.SpecifierManager specifierManager)
-
-
Method Details
-
initPopup
public void initPopup() -
getTableCellRendererComponent
public Component getTableCellRendererComponent(JTable tableNullable, Object value, boolean isSelected, boolean hasFocus, int row, int column) - Specified by:
getTableCellRendererComponentin interfaceTableCellRenderer- Overrides:
getTableCellRendererComponentin classTextCellRenderer<String>
-
getSwingViewSubNodes
Description copied from interface:GuiSwingFeatureIt returns a list of sub-nodes of the node.A sub-node is a displayable view under the same window, a displayable view under the different window, or a non-displayable element.
If this is a
Container, it typically returnsContainer.getComponents().A sub-node might have a different context or a shared context with
GuiSwingFeature.getSwingViewContext()of this.- Specified by:
getSwingViewSubNodesin interfaceGuiSwingElement.FeatureCollection- Specified by:
getSwingViewSubNodesin interfaceGuiSwingFeature- Specified by:
getSwingViewSubNodesin interfaceGuiSwingView.ValuePane<String>- Specified by:
getSwingViewSubNodesin interfaceObjectTableColumnValue.ObjectTableColumnCellView- Returns:
- a list of sub-nodes
-
getSwingViewValue
- Specified by:
getSwingViewValuein interfaceGuiSwingView.ValuePane<String>- Returns:
- basically, the source value of the context, held by the component without touching the context.
-
setSwingViewValue
Description copied from interface:GuiSwingView.ValuePaneupdate GUI display, and it does NOT update the target model value. processed under the event thread. also increment the view-clock.- Specified by:
setSwingViewValuein interfaceGuiSwingView.ValuePane<String>- Parameters:
value- the new value
-
setSwingViewValue
Description copied from interface:GuiSwingView.ValuePaneupdate 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:
setSwingViewValuein interfaceGuiSwingView.ValuePane<String>- 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.ValuePaneupdate the GUI display and the model. processed under the event thread. also increment the view-clock- Specified by:
setSwingViewValueWithUpdatein interfaceGuiSwingView.ValuePane<String>- Parameters:
value- the new value
-
setSwingViewValueWithUpdate
Description copied from interface:GuiSwingView.ValuePaneupdate 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:
setSwingViewValueWithUpdatein interfaceGuiSwingView.ValuePane<String>- Parameters:
value- the new valueclock- the clock of the value
-
getSwingStaticMenuItems
Description copied from interface:GuiSwingView.ValuePanea 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:
getSwingStaticMenuItemsin interfaceGuiSwingView.ValuePane<String>- Returns:
- a list of actions (or menu-components) statically determined, that should be always same instances
-
getSwingMenuBuilder
Description copied from interface:GuiSwingView.ValuePanea typical implementation if there are no dynamic items becomes like the following code:if (popup == null) { popup = newPopupExtension(this, newPopupCategorized(this::getSwingStaticMenuItems)); } return popup.getMenuBuilder();- Specified by:
getSwingMenuBuilderin interfaceGuiSwingView.ValuePane<String>- Returns:
- a menu builder
-
getSwingViewContext
- Specified by:
getSwingViewContextin interfaceGuiSwingFeature
-
getMenuTargetPane
- Specified by:
getMenuTargetPanein interfaceObjectTableColumn.PopupMenuBuilderSource- Returns:
- a setter for the pane or null
-
getSpecifier
- Specified by:
getSpecifierin interfaceGuiSwingFeature- Returns:
- the specifier for the context value, typically obtained from
GuiSwingView.SpecifierManager
-
getMenuBuilder
- Specified by:
getMenuBuilderin interfaceObjectTableColumn.PopupMenuBuilderSource
-
getHeaderMenuItems
- Specified by:
getHeaderMenuItemsin interfaceObjectTableColumn.PopupMenuBuilderSourceForHeader- Parameters:
table- the target table- Returns:
- menu-items for a column in the table
-
getComponent
- Specified by:
getComponentin interfaceObjectTableColumnValue.ObjectTableColumnCellView
-
setOwnerColumn
- Specified by:
setOwnerColumnin interfaceObjectTableColumnValue.ObjectTableColumnValueRenderer
-
getOwnerColumn
- Specified by:
getOwnerColumnin interfaceObjectTableColumnValue.ObjectTableColumnValueRenderer
-
buildFromValue
public void buildFromValue()- Overrides:
buildFromValuein classTextCellRenderer<String>
-
createLayoutForPaintOrLayout
protected TextLayout createLayoutForPaintOrLayout(boolean paint, TextCellRenderer.LineInfo line, FontRenderContext frc, Color foregroundColor, Color backgroundColor, Color selectionTextColor, Color selectionColor) Description copied from class:TextCellRenderercalled fromTextCellRenderer.paintOrLayoutComponentLines(Graphics, boolean)and obtains a text-layout object for the line- Overrides:
createLayoutForPaintOrLayoutin classTextCellRenderer<String>- Parameters:
paint- the paint or layout modeline- the source linefrc- the font rendering contextforegroundColor- the text colorbackgroundColor- the background colorselectionTextColor- the selected text colorselectionColor- the selected background color- Returns:
- obtaining text-layout from the line
-