Package jmri.jmrit.display.palette
Class BackgroundItemPanel
- java.lang.Object
-
- java.awt.Component
-
- java.awt.Container
-
- javax.swing.JComponent
-
- javax.swing.JPanel
-
- jmri.jmrit.display.palette.ItemPanel
-
- jmri.jmrit.display.palette.IconItemPanel
-
- jmri.jmrit.display.palette.BackgroundItemPanel
-
- All Implemented Interfaces:
java.awt.image.ImageObserver
,java.awt.MenuContainer
,java.io.Serializable
,javax.accessibility.Accessible
public class BackgroundItemPanel extends IconItemPanel
JPanels for the Panel Backgrounds.- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class jmri.jmrit.display.palette.IconItemPanel
IconItemPanel.ADropJLabel, IconItemPanel.ADropTargetListener, IconItemPanel.IconDisplayPanel, IconItemPanel.IconDragJLabel, IconItemPanel.IconListener
-
Nested classes/interfaces inherited from class javax.swing.JPanel
javax.swing.JPanel.AccessibleJPanel
-
Nested classes/interfaces inherited from class javax.swing.JComponent
javax.swing.JComponent.AccessibleJComponent
-
-
Field Summary
Fields Modifier and Type Field Description (package private) javax.swing.JColorChooser
_chooser
(package private) java.awt.Color
_color
(package private) javax.swing.JButton
_colorButton
(package private) javax.swing.JPanel
_colorPanel
-
Fields inherited from class jmri.jmrit.display.palette.IconItemPanel
_catalog, _catalogButton, _deleteIconButton, _level, _namedIconDataFlavor, _positionableDataFlavor, _selectedIcon
-
Fields inherited from class jmri.jmrit.display.palette.ItemPanel
_askOnce, _bottomPanel, _currentIconMap, _doneAction, _frame, _iconFamilyPanel, _iconPanel, _initialized, _instructions, _itemType, _linkName, _previewPanel, _suppressDragging, _update, _wasEmpty, INDICATOR_TRACK, LIGHT, MULTISENSOR, NAME_MAP, PORTAL, RPSREPORTER, SENSOR, SIGNALHEAD, STATE_MAP, TURNOUT
-
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
-
-
Constructor Summary
Constructors Constructor Description BackgroundItemPanel(DisplayFrame parentFrame, java.lang.String type)
Constructor for background of icons or panel color.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
init()
Initialize panel for selecting a new Control Panel item or for updating an existing item.protected void
initLinkPanel()
protected javax.swing.JPanel
instructions()
protected javax.swing.JPanel
makeColorButtonPanel()
protected javax.swing.JPanel
makeItemButtonPanel()
Make a button panel to populate editing an ItemPanelprotected javax.swing.JPanel
makeSpecialBottomPanel(boolean update)
Replacement panel for _bottomPanel when no icon families exist for _itemType.protected void
previewColorChange()
protected void
showCatalog()
-
Methods inherited from class jmri.jmrit.display.palette.IconItemPanel
deleteIcon, deselectIcon, getUpdateIcon, hideCatalog, hideIcons, init, initIconFamiliesPanel, makeCatalog, makeFamiliesPanel, makeIconDisplayPanel, putIcon, setIconName, setSelection, setUpdateIcon
-
Methods inherited from class jmri.jmrit.display.palette.ItemPanel
addIconsToPanel, checkIconMap, closeDialogs, itemGridBagConstraint, loadDefaultType, makeBottomPanel, makeNewIconMap, makePreviewPanel, makeUpdateButton, mapsAreEqual, reSizeDisplay, shellDimension, wrapIconImage
-
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI
-
Methods inherited from class javax.swing.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, paintComponent, 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, 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, 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, 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
-
-
-
-
Field Detail
-
_chooser
javax.swing.JColorChooser _chooser
-
_colorButton
javax.swing.JButton _colorButton
-
_colorPanel
javax.swing.JPanel _colorPanel
-
_color
java.awt.Color _color
-
-
Constructor Detail
-
BackgroundItemPanel
public BackgroundItemPanel(DisplayFrame parentFrame, java.lang.String type)
Constructor for background of icons or panel color.- Parameters:
parentFrame
- ItemPalette instancetype
- identifier of the ItemPanel type, should be "Background"
-
-
Method Detail
-
init
public void init()
Description copied from class:ItemPanel
Initialize panel for selecting a new Control Panel item or for updating an existing item. Adds table if item is a bean. i.e. customizes for the item type. Called by enclosing TabbedPanel on change of displayed tab Pane.- Overrides:
init
in classIconItemPanel
-
instructions
protected javax.swing.JPanel instructions()
- Overrides:
instructions
in classIconItemPanel
-
makeItemButtonPanel
protected javax.swing.JPanel makeItemButtonPanel()
Description copied from class:ItemPanel
Make a button panel to populate editing an ItemPanel- Overrides:
makeItemButtonPanel
in classIconItemPanel
- Returns:
- the panel
-
makeSpecialBottomPanel
protected javax.swing.JPanel makeSpecialBottomPanel(boolean update)
Description copied from class:IconItemPanel
Replacement panel for _bottomPanel when no icon families exist for _itemType.- Overrides:
makeSpecialBottomPanel
in classIconItemPanel
- Parameters:
update
- edit icons on a panel- Returns:
- the panel
-
initLinkPanel
protected void initLinkPanel()
- Overrides:
initLinkPanel
in classIconItemPanel
-
showCatalog
protected void showCatalog()
- Overrides:
showCatalog
in classIconItemPanel
-
makeColorButtonPanel
protected javax.swing.JPanel makeColorButtonPanel()
-
previewColorChange
protected void previewColorChange()
- Overrides:
previewColorChange
in classIconItemPanel
-
-