@ColorCodes(value={"title.active.left","title.inactive.left","title.disabled.left","title.active.right","title.inactive.right","title.disabled.right","title.active.text","title.inactive.text"}) public class BasicDockTitle extends AbstractDockTitle
JPanel.AccessibleJPanelJComponent.AccessibleJComponentContainer.AccessibleAWTContainerComponent.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategyDockTitle.Orientation| Modifier and Type | Field and Description |
|---|---|
static DockTitleFactory |
FACTORY
A factory for the
BasicDockTitle. |
listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOWaccessibleContext, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENTORIENTATION_STRATEGYABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH| Modifier | Constructor and Description |
|---|---|
|
BasicDockTitle(Dockable dockable,
DockTitleVersion origin)
Creates a new title
|
protected |
BasicDockTitle(Dockable dockable,
DockTitleVersion origin,
boolean setDefaultConditionalFonts)
Creates a new title
|
| Modifier and Type | Method and Description |
|---|---|
Color |
getActiveLeftColor()
Gets the color that is used on the left side if this title
is active.
|
TitleColor |
getActiveLeftTitleColor()
Gets the handle for the left active color.
|
Color |
getActiveRightColor()
Gets the color that is used on the right side in the
gradient of this title.
|
TitleColor |
getActiveRightTitleColor()
Gets the handle for the left active color.
|
Color |
getActiveTextColor()
Gets the color that is used for text if this title is active.
|
TitleColor |
getActiveTextTitleColor()
Gets a handle for the foreground color of an active title.
|
Color |
getDisabledLeftColor()
Gets the color that is used on the left side if this title is disabled.
|
TitleColor |
getDisabledLeftTitleColor()
Gets the handle for the left disabled color.
|
Color |
getDisabledRightColor()
Gets the color that is used on the right side if this title is disabled.
|
TitleColor |
getDisabledRightTitleColor()
Gets the handle for the right disabled color.
|
protected GradientPaint |
getGradient(Color left,
Color right,
Component component)
Gets the gradient which is used to fill the background of
component. |
Color |
getInactiveLeftColor()
Gets the color which is used on the left side of the
gradient if this title is not active.
|
TitleColor |
getInactiveLeftTitleColor()
Gets a handle for the left inactive color.
|
Color |
getInactiveRightColor()
Gets the color which is used on the right side of the
gradient if this title is not active.
|
TitleColor |
getInactiveRightTitleColor()
Gets a handle for the inactive right background color.
|
Color |
getInactiveTextColor()
Gets the color of the text.
|
TitleColor |
getInactiveTextTitleColor()
Gets a handle for the inactive foreground color.
|
protected void |
paintBackground(Graphics g,
JComponent component)
Paints the whole background of this title.
|
void |
reshape(int x,
int y,
int w,
int h)
Deprecated.
|
void |
setActive(boolean active)
Sets whether this title should be painted as focused or not.
|
void |
setActiveLeftColor(Color activeLeftColor)
Sets the color that is used on the left side if this
title is active.
|
void |
setActiveLeftColorId(String id)
Changes the identifier that is used for the active left color.
|
void |
setActiveRightColor(Color activeRightColor)
Sets the color which is used on the right side in the
gradient of this title.
|
void |
setActiveRightColorId(String id)
Changes the identifier that is used for the active right color.
|
void |
setActiveTextColor(Color activeTextColor)
Sets the color which is used to paint the text if this title
is active.
|
void |
setActiveTextColorId(String id)
Changes the identifier that is used for the active text color.
|
protected void |
setDisabled(boolean disabled)
Tells this title whether it should be disabled or not.
|
void |
setDisabledLeftColor(Color disabledLeftColor)
Sets the color that is used on the left side if this
title is disabled.
|
void |
setDisabledLeftColorId(String id)
Changes the identifier that is used for the disabled left color.
|
void |
setDisabledRightColor(Color disabledRightColor)
Sets the color that is used on the right side if this
title is disabled.
|
void |
setDisabledRightColorId(String id)
Changes the identifier that is used for the disabled right color.
|
void |
setInactiveLeftColor(Color inactiveLeftColor)
Sets the color which will be used on the left side of
the gradient if this title is not active.
|
void |
setInactiveLeftColorId(String id)
Changes the identifier that is used for the inactive left color.
|
void |
setInactiveRightColor(Color inactiveRightColor)
Sets the color of the right side of the gradient.
|
void |
setInactiveRightColorId(String id)
Changes the identifier that is used for the inactive right color.
|
void |
setInactiveTextColor(Color inactiveTextColor)
Sets the color of the text.
|
void |
setInactiveTextColorId(String id)
Changes the identifier that is used for the inactive text color.
|
void |
setOrientation(DockTitle.Orientation orientation)
Sets the orientation of this title.
|
protected void |
updateColors()
Invoked after a color has changed.
|
void |
validate() |
bind, changed, doTitleLayout, getActionSourceFor, getPopupLocation, getPreferredSize, getSuggestedSource, init, isShowMiniButtons, setShowMiniButtons, setTooltip, suggestActions, unbindaddColor, addConditionalFont, addFont, addMouseInputListener, createItemFor, createRootHandler, doLayout, getComponentConfiguration, getDockable, getElement, getIcon, getIconBounds, getIconTextGap, getInnerInsets, getLabel, getMinimumSize, getOrientation, getOrigin, getText, init, isActive, isBound, isDisabled, isUsedAsTitle, paintBackground, paintForeground, paintForeground, paintIcon, removeAllConditionalFonts, removeColor, removeFont, removeMouseInputListener, setBackground, setBorder, setComponentConfiguration, setFont, setFontModifier, setForeground, setIcon, setIconTextGap, setText, setupRenderingHints, shouldFocus, shouldTransfersFocus, titleInsets, updateFonts, updateIcon, updateText, updateTooltipconfiguregetBackgroundAlgorithm, getComponent, getTransparency, paint, paintBorder, paintChildren, paintComponent, paintOverlay, setBackground, setTransparencygetAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUIaddAncestorListener, 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, getNextFocusableComponent, getPopupLocation, 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, 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, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, updateadd, 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, validateTreeaction, 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, getPeer, 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, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycleclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetComponentpublic static final DockTitleFactory FACTORY
BasicDockTitle.public BasicDockTitle(Dockable dockable, DockTitleVersion origin)
dockable - the owner of this titleorigin - the version which was used to create this titleprotected BasicDockTitle(Dockable dockable, DockTitleVersion origin, boolean setDefaultConditionalFonts)
dockable - the owner of this titleorigin - the version which was used to create this titlesetDefaultConditionalFonts - whether to set the default set of
conditional fonts for DockFont.ID_TITLE_ACTIVE and
DockFont.ID_TITLE_INACTIVE@Deprecated public void reshape(int x, int y, int w, int h)
reshape in class JComponentpublic void setOrientation(DockTitle.Orientation orientation)
DockTitlesetOrientation in interface DockTitlesetOrientation in class AbstractDockTitleorientation - the orientationprotected void paintBackground(Graphics g, JComponent component)
AbstractMultiDockTitlecomponent.paintBackground in class AbstractMultiDockTitleg - the graphics context used to paintcomponent - the Component which represents this titleprotected GradientPaint getGradient(Color left, Color right, Component component)
component.left - the first color of the gradientright - the second color of the gradientcomponent - the component on which the gradient will be usedpublic Color getActiveLeftColor()
getActiveLeftTitleColor().color();.setActiveLeftColor(Color),
getActiveLeftTitleColor()public TitleColor getActiveLeftTitleColor()
public void setActiveLeftColor(Color activeLeftColor)
getActiveLeftTitleColor().setValue( activeLeftColor );.activeLeftColor - the colorgetActiveLeftTitleColor()public void setActiveLeftColorId(String id)
id - the new identifier, not nullpublic Color getActiveRightColor()
getActiveRightTitleColor().color();.public TitleColor getActiveRightTitleColor()
public void setActiveRightColor(Color activeRightColor)
getActiveRightTitleColor().setValue( activeRightColor );.activeRightColor - the colorpublic void setActiveRightColorId(String id)
id - the new identifier, not nullpublic Color getActiveTextColor()
getActiveTextTitleColor().color();.public TitleColor getActiveTextTitleColor()
public void setActiveTextColor(Color activeTextColor)
getActiveTextTitleColor().setValue( activeTextColor );.activeTextColor - the colorpublic void setActiveTextColorId(String id)
id - the new identifier, not nullpublic Color getDisabledLeftColor()
getDisabledLeftTitleColor().color();.setDisabledLeftColor(Color),
getDisabledLeftTitleColor()public TitleColor getDisabledLeftTitleColor()
public void setDisabledLeftColor(Color disabledLeftColor)
getDisabledLeftTitleColor().setValue( activeLeftColor );.disabledLeftColor - the colorgetDisabledLeftTitleColor()public void setDisabledLeftColorId(String id)
id - the new identifier, not nullpublic Color getDisabledRightColor()
getDisabledRightTitleColor().color();.setDisabledRightColor(Color),
getDisabledRightTitleColor()public TitleColor getDisabledRightTitleColor()
public void setDisabledRightColor(Color disabledRightColor)
getDisabledRightTitleColor().setValue( activeLeftColor );.disabledRightColor - the colorgetDisabledRightTitleColor()public void setDisabledRightColorId(String id)
id - the new identifier, not nullpublic Color getInactiveLeftColor()
getInactiveLeftTitleColor().color();.public TitleColor getInactiveLeftTitleColor()
public void setInactiveLeftColor(Color inactiveLeftColor)
getInactiveLeftTitleColor().setValue( inactiveLeftColor );.inactiveLeftColor - the colorpublic void setInactiveLeftColorId(String id)
id - the new identifier, not nullpublic Color getInactiveRightColor()
getInactiveRightTitleColor().color();.public TitleColor getInactiveRightTitleColor()
public void setInactiveRightColor(Color inactiveRightColor)
getInactiveRightTitleColor().setValue( inactiveRightColor );.inactiveRightColor - the colorpublic void setInactiveRightColorId(String id)
id - the new identifier, not nullpublic Color getInactiveTextColor()
getInactiveTextTitleColor().color();.public TitleColor getInactiveTextTitleColor()
public void setInactiveTextColor(Color inactiveTextColor)
getInactiveTextTitleColor().setValue( inactiveTextColor );.inactiveTextColor - the colorpublic void setInactiveTextColorId(String id)
id - the new identifier, not nullpublic void setActive(boolean active)
AbstractMultiDockTitlesetActive in class AbstractMultiDockTitleactive - true if the Dockable of this title
has the focus.protected void setDisabled(boolean disabled)
AbstractMultiDockTitleDisablingStrategy
changes. A disabled title should react to any InputEvent, and should be painted differently than an
enabled title.setDisabled in class AbstractMultiDockTitledisabled - whether this title is disabledAbstractMultiDockTitle.isDisabled()protected void updateColors()
Copyright © 2017 Docking Frames. All rights reserved.