Class RadianceRibbonTaskToggleButtonUI
- java.lang.Object
-
- javax.swing.plaf.ComponentUI
-
- javax.swing.plaf.ButtonUI
-
- org.pushingpixels.radiance.component.internal.ui.common.CommandButtonUI
-
- org.pushingpixels.radiance.component.internal.ui.common.BasicCommandButtonUI
-
- org.pushingpixels.radiance.component.internal.ui.ribbon.BasicRibbonTaskToggleButtonUI
-
- org.pushingpixels.radiance.component.internal.theming.ribbon.ui.RadianceRibbonTaskToggleButtonUI
-
- All Implemented Interfaces:
TransitionAwareUI
public class RadianceRibbonTaskToggleButtonUI extends BasicRibbonTaskToggleButtonUI implements TransitionAwareUI
UI forJRibbonTaskToggleButton
components in Radiance look and feel.
-
-
Field Summary
Fields Modifier and Type Field Description private RibbonTaskToggleButtonBackgroundDelegate
delegate
Painting delegate.private java.beans.PropertyChangeListener
radiancePropertyChangeListener
Property change listener on the button.private CommandButtonVisualStateTracker
radianceVisualStateTracker
Tracker for visual state transitions.-
Fields inherited from class org.pushingpixels.radiance.component.internal.ui.common.BasicCommandButtonUI
backgroundAppearanceStrategy, commandButton, DO_NOT_DISPOSE_POPUPS, extraText, horizontalAlignment, icon, isInnerFocusOnAction, layoutInfo, layoutManager, popupIcon, text
-
-
Constructor Summary
Constructors Modifier Constructor Description private
RadianceRibbonTaskToggleButtonUI()
Simple constructor.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static javax.swing.plaf.ComponentUI
createUI(javax.swing.JComponent comp)
private static java.awt.Color
getForegroundColor(JCommandButton button, StateTransitionTracker.ModelStateInfo modelStateInfo)
java.awt.Dimension
getPreferredSize(javax.swing.JComponent c)
StateTransitionTracker
getTransitionTracker()
Returns the model for tracking the transitions.protected void
installDefaults()
Installs defaults on the associated command button.protected void
installListeners()
Installs listeners on the associated command button.boolean
isInside(java.awt.event.MouseEvent me)
Checks whether the mouse position of the specified event lies inside the area of the component designated for transition effects.void
paint(java.awt.Graphics g, javax.swing.JComponent c)
private void
paintTextAndFocus(java.awt.Graphics g)
protected void
uninstallComponents()
Uninstalls subcomponents from the associated command button.protected void
uninstallDefaults()
Uninstalls defaults from the associated command button.protected void
uninstallListeners()
Uninstalls listeners from the associated command button.void
update(java.awt.Graphics g, javax.swing.JComponent c)
-
Methods inherited from class org.pushingpixels.radiance.component.internal.ui.ribbon.BasicRibbonTaskToggleButtonUI
getMinimumSize
-
Methods inherited from class org.pushingpixels.radiance.component.internal.ui.common.BasicCommandButtonUI
createButtonListener, createPopupActionListener, getActionKeyTipAnchorCenterPoint, getLayoutInfo, getLayoutManager, getPopupKeyTipAnchorCenterPoint, installComponents, installKeyboardActions, installUI, isInnerFocusOnAction, isPaintingBackground, isPaintingSeparators, processPopupAction, setInnerFocusOnAction, uninstallKeyboardActions, uninstallUI, updatePopupIcon
-
-
-
-
Field Detail
-
radianceVisualStateTracker
private CommandButtonVisualStateTracker radianceVisualStateTracker
Tracker for visual state transitions.
-
radiancePropertyChangeListener
private java.beans.PropertyChangeListener radiancePropertyChangeListener
Property change listener on the button.
-
delegate
private RibbonTaskToggleButtonBackgroundDelegate delegate
Painting delegate.
-
-
Method Detail
-
createUI
public static javax.swing.plaf.ComponentUI createUI(javax.swing.JComponent comp)
-
installDefaults
protected void installDefaults()
Description copied from class:BasicCommandButtonUI
Installs defaults on the associated command button.- Overrides:
installDefaults
in classBasicCommandButtonUI
-
uninstallDefaults
protected void uninstallDefaults()
Description copied from class:BasicCommandButtonUI
Uninstalls defaults from the associated command button.- Overrides:
uninstallDefaults
in classBasicCommandButtonUI
-
uninstallComponents
protected void uninstallComponents()
Description copied from class:BasicCommandButtonUI
Uninstalls subcomponents from the associated command button.- Overrides:
uninstallComponents
in classBasicCommandButtonUI
-
installListeners
protected void installListeners()
Description copied from class:BasicCommandButtonUI
Installs listeners on the associated command button.- Overrides:
installListeners
in classBasicRibbonTaskToggleButtonUI
-
uninstallListeners
protected void uninstallListeners()
Description copied from class:BasicCommandButtonUI
Uninstalls listeners from the associated command button.- Overrides:
uninstallListeners
in classBasicRibbonTaskToggleButtonUI
-
paint
public void paint(java.awt.Graphics g, javax.swing.JComponent c)
- Overrides:
paint
in classjavax.swing.plaf.ComponentUI
-
update
public void update(java.awt.Graphics g, javax.swing.JComponent c)
- Overrides:
update
in classBasicCommandButtonUI
-
paintTextAndFocus
private void paintTextAndFocus(java.awt.Graphics g)
-
getForegroundColor
private static java.awt.Color getForegroundColor(JCommandButton button, StateTransitionTracker.ModelStateInfo modelStateInfo)
-
getPreferredSize
public java.awt.Dimension getPreferredSize(javax.swing.JComponent c)
- Overrides:
getPreferredSize
in classBasicCommandButtonUI
-
getTransitionTracker
public StateTransitionTracker getTransitionTracker()
Description copied from interface:TransitionAwareUI
Returns the model for tracking the transitions.- Specified by:
getTransitionTracker
in interfaceTransitionAwareUI
- Returns:
- Model for tracking the transitions.
-
isInside
public boolean isInside(java.awt.event.MouseEvent me)
Description copied from interface:TransitionAwareUI
Checks whether the mouse position of the specified event lies inside the area of the component designated for transition effects.- Specified by:
isInside
in interfaceTransitionAwareUI
- Parameters:
me
- Mouse event.- Returns:
true
if the mouse position of the specified event lies inside the area of the component designated for transition effects,false
otherwise.
-
-