public class SlidingTabDisplayerButtonUI extends BasicToggleButtonUI
BasicSlidingTabDisplayerUI.
Uses the lightweight HTML renderer for good performance when rendering HTML strings. It is
intended as a UI for BasicSlidingTabDisplayerUI.IndexButton. Provide a subclass
of this class via UIDefaults to change the painting behavior or appearance of the tab buttons in
"sliding" style tabbed controls. Typically the only method of interest when
subclassing is paintBackground(java.awt.Graphics2D, org.netbeans.swing.tabcontrol.plaf.BasicSlidingTabDisplayerUI.IndexButton).
As with its superclass BasicToggleButtonUI, instances of this class should be stateless,
such that a single instance can manage any number of buttons.
| Modifier and Type | Class and Description |
|---|---|
static class |
SlidingTabDisplayerButtonUI.Aqua
Deprecated.
No brushed metal look and feel doesn't need this class anymore.
|
defaultTextIconGap, defaultTextShiftOffset| Modifier | Constructor and Description |
|---|---|
protected |
SlidingTabDisplayerButtonUI()
Creates a new instance of SlidingTabDisplayerButtonUI
|
| Modifier and Type | Method and Description |
|---|---|
static ComponentUI |
createUI(JComponent c) |
Dimension |
getMaximumSize(JComponent c) |
Dimension |
getMinimumSize(JComponent c) |
Dimension |
getPreferredSize(JComponent c) |
protected void |
installBorder(AbstractButton b)
Install a border on the button
|
void |
installDefaults(AbstractButton b)
Overridden to not call super.installDefaults() and only set the button
to be non-focusable
|
void |
installUI(JComponent c)
Overridden to not install keyboard actions (the buttons aren't focusable
anyway) and not invoke the overhead of BasicHTML
|
void |
paint(Graphics g,
JComponent c)
Provides the painting logic.
|
protected void |
paintBackground(Graphics2D g,
BasicSlidingTabDisplayerUI.IndexButton b)
Paints the tab background
|
protected void |
paintIconAndText(Graphics2D g,
BasicSlidingTabDisplayerUI.IndexButton b,
Object orientation)
Paints the icon and text using the HTML mini renderer
|
void |
uninstallUI(JComponent c)
Overridden to not uninstall keyboard actions (the buttons aren't focusable
anyway) and not invoke the overhead of BasicHTML
|
getPropertyPrefix, getTextShiftOffset, paintIconclearTextShiftOffset, createButtonListener, getBaseline, getBaselineResizeBehavior, getDefaultTextIconGap, installKeyboardActions, installListeners, paintButtonPressed, paintFocus, paintIcon, paintText, paintText, setTextShiftOffset, uninstallDefaults, uninstallKeyboardActions, uninstallListenerscontains, getAccessibleChild, getAccessibleChildrenCount, updateprotected SlidingTabDisplayerButtonUI()
public static ComponentUI createUI(JComponent c)
public void installUI(JComponent c)
installUI in class BasicButtonUIprotected void installBorder(AbstractButton b)
public void uninstallUI(JComponent c)
uninstallUI in class BasicButtonUIpublic void installDefaults(AbstractButton b)
installDefaults in class BasicButtonUIpublic Dimension getMinimumSize(JComponent c)
getMinimumSize in class BasicButtonUIpublic Dimension getPreferredSize(JComponent c)
getPreferredSize in class BasicButtonUIpublic Dimension getMaximumSize(JComponent c)
getMaximumSize in class BasicButtonUIpublic final void paint(Graphics g, JComponent c)
paint in class BasicToggleButtonUIprotected void paintBackground(Graphics2D g, BasicSlidingTabDisplayerUI.IndexButton b)
protected final void paintIconAndText(Graphics2D g, BasicSlidingTabDisplayerUI.IndexButton b, Object orientation)
Built on May 22 2013. | Portions Copyright 1997-2013 Oracle. All rights reserved.