Class BasicRibbonApplicationMenuButtonUI
- java.lang.Object
-
- javax.swing.plaf.ComponentUI
-
- javax.swing.plaf.ButtonUI
-
- org.pushingpixels.flamingo.internal.ui.common.CommandButtonUI
-
- org.pushingpixels.flamingo.internal.ui.common.BasicCommandButtonUI
-
- org.pushingpixels.flamingo.internal.ui.ribbon.appmenu.BasicRibbonApplicationMenuButtonUI
-
public class BasicRibbonApplicationMenuButtonUI extends BasicCommandButtonUI
Basic UI for ribbon application menu buttonJRibbonApplicationMenuButton.
-
-
Field Summary
Fields Modifier and Type Field Description protected JRibbonApplicationMenuButtonapplicationMenuButtonThe associated application menu button.-
Fields inherited from class org.pushingpixels.flamingo.internal.ui.common.BasicCommandButtonUI
basicPopupButtonListener, buttonRendererPane, commandButton, disposePopupsActionListener, DONT_DISPOSE_POPUPS, EMULATE_SQUARE_BUTTON, isUnderMouse, layoutInfo, layoutManager, popupActionIcon, popupActionListener, propertyChangeListener, rendererButton, rendererSeparator
-
-
Constructor Summary
Constructors Constructor Description BasicRibbonApplicationMenuButtonUI(JRibbon ribbon)Constructs aBasicRibbonApplicationMenuButtonUIspecifying theJRibbonthe button UI is created for.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidconfigureRenderer()static ComponentUIcreateUI(JComponent component)Creates a UI delegate for aJRibbonApplicationMenuButton.JRibbongetRibbon()Returns the ribbon reference this button UI is created for.protected voidinstallComponents()Installs subcomponents on the associated command button.protected voidinstallDefaults()Installs defaults on the associated command button.voidinstallUI(JComponent c)voidpaint(Graphics g, JComponent c)protected voidpaintButtonBackground(Graphics graphics, Rectangle toFill)Paints the button background.protected voidsetRibbon(JRibbon ribbon)Sets the ribbon this button UI is created for.protected voidunconfigureRenderer()-
Methods inherited from class org.pushingpixels.flamingo.internal.ui.common.BasicCommandButtonUI
createButtonListener, createPopupActionIcon, createPopupActionListener, createRendererButton, getForegroundColor, getIconToPaint, getKeyTipAnchorCenterPoint, getLayoutGap, getLayoutInfo, getPreferredSize, installKeyboardActions, installListeners, isPaintingBackground, isPaintingSeparators, paintButtonBackground, paintButtonHorizontalSeparator, paintButtonIcon, paintButtonVerticalSeparator, paintPopupActionIcon, processPopupAction, syncDisabledIcon, syncIconDimension, toUseDisabledIcon, uninstallComponents, uninstallDefaults, uninstallKeyboardActions, uninstallListeners, uninstallUI, update, updateBorder, updateCustomDimension, updatePopupActionIcon
-
Methods inherited from class javax.swing.plaf.ComponentUI
contains, getAccessibleChild, getAccessibleChildrenCount, getBaseline, getBaselineResizeBehavior, getMaximumSize, getMinimumSize
-
-
-
-
Field Detail
-
applicationMenuButton
protected JRibbonApplicationMenuButton applicationMenuButton
The associated application menu button.
-
-
Constructor Detail
-
BasicRibbonApplicationMenuButtonUI
public BasicRibbonApplicationMenuButtonUI(JRibbon ribbon)
Constructs aBasicRibbonApplicationMenuButtonUIspecifying theJRibbonthe button UI is created for.- Parameters:
ribbon- the ribbon
-
-
Method Detail
-
createUI
public static ComponentUI createUI(JComponent component)
Creates a UI delegate for aJRibbonApplicationMenuButton. TheJRibbonthe menu button belongs to is required in order to create this UI.The
componentmay be a supported object instance which is aJRibbonor has a reference to the applicationJRibbon.- Parameters:
component- aJRibbonto be used as criteria for creating the UI for a newBasicRibbonApplicationMenuButtonUI- Throws:
IllegalArgumentException- ifcomponentis not aJRibbon- See Also:
ComponentUI.createUI(javax.swing.JComponent)
-
getRibbon
public JRibbon getRibbon()
Returns the ribbon reference this button UI is created for.- Returns:
- the ribbon reference
-
setRibbon
protected void setRibbon(JRibbon ribbon)
Sets the ribbon this button UI is created for.- Parameters:
ribbon- the ribbon
-
installUI
public void installUI(JComponent c)
- Overrides:
installUIin classBasicCommandButtonUI
-
installDefaults
protected void installDefaults()
Description copied from class:BasicCommandButtonUIInstalls defaults on the associated command button.- Overrides:
installDefaultsin classBasicCommandButtonUI
-
configureRenderer
protected void configureRenderer()
- Overrides:
configureRendererin classBasicCommandButtonUI
-
unconfigureRenderer
protected void unconfigureRenderer()
- Overrides:
unconfigureRendererin classBasicCommandButtonUI
-
installComponents
protected void installComponents()
Description copied from class:BasicCommandButtonUIInstalls subcomponents on the associated command button.- Overrides:
installComponentsin classBasicCommandButtonUI
-
paint
public void paint(Graphics g, JComponent c)
- Overrides:
paintin classBasicCommandButtonUI
-
paintButtonBackground
protected void paintButtonBackground(Graphics graphics, Rectangle toFill)
Paints the button background.- Overrides:
paintButtonBackgroundin classBasicCommandButtonUI- Parameters:
graphics- Graphics context.toFill- Rectangle to fill.
-
-