Class BasicRibbonBandUI
java.lang.Object
javax.swing.plaf.ComponentUI
org.pushingpixels.flamingo.internal.ui.ribbon.RibbonBandUI
org.pushingpixels.flamingo.internal.ui.ribbon.BasicRibbonBandUI
Basic UI for ribbon band
JRibbonBand.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static classPopup panel that shows the contents of the ribbon band when it is in a collapsed state.protected static classRound border for the ribbon bands. -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected JCommandButtonThe button for collapsed state.protected AbstractCommandButtonThe band expand button.protected ActionListenerAction listener on the expand button.protected MouseListenerMouse listener on the associated ribbon band.protected PropertyChangeListenerListens to property changes on the associated ribbon band.protected AbstractRibbonBand<AbstractBandControlPanel>The associated ribbon band.protected floatprotected org.pushingpixels.trident.Timeline -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidprotected JCommandButtonCreates the expand button for the associated ribbon band.protected LayoutManagerInvoked byinstallUIto create a layout manager object to manage theJCommandButtonStrip.static ComponentUIintReturns the height of the ribbon band title area.Deprecated.Deprecated.intfloatprotected voidInstalls subcomponents on the associated ribbon band.protected voidInstalls default parameters on the associated ribbon band.protected voidInstalls listeners on the associated ribbon band.voidvoidpaint(Graphics g, JComponent c) protected voidpaintBandBackground(Graphics graphics, Rectangle toFill) Paints band background.protected voidpaintBandTitle(Graphics g, Rectangle titleRectangle, String title) Paints band title pane.protected voidpaintBandTitleBackground(Graphics g, Rectangle titleRectangle, String title) Paints band title pane.voidsetRolloverAmount(float rolloverAmount) protected voidvoidtrackMouseCrossing(boolean isMouseIn) protected voidprotected voidUninstalls components from the associated ribbon band.protected voidUninstalls default parameters from the associated ribbon band.protected voidUninstalls listeners from the associated ribbon band.voidvoidupdate(Graphics g, JComponent c) Methods inherited from class javax.swing.plaf.ComponentUI
contains, getAccessibleChild, getAccessibleChildrenCount, getBaseline, getBaselineResizeBehavior, getMaximumSize, getMinimumSize, getPreferredSize
-
Field Details
-
ribbonBand
The associated ribbon band. -
collapsedButton
The button for collapsed state. -
expandButton
The band expand button. Is visible when theAbstractRibbonBand.getExpandActionListener()of the associated ribbon band is notnull. -
rolloverAmount
protected float rolloverAmount -
rolloverTimeline
protected org.pushingpixels.trident.Timeline rolloverTimeline -
mouseListener
Mouse listener on the associated ribbon band. -
propertyChangeListener
Listens to property changes on the associated ribbon band. -
expandButtonActionListener
Action listener on the expand button.
-
-
Constructor Details
-
BasicRibbonBandUI
public BasicRibbonBandUI()
-
-
Method Details
-
createUI
-
installUI
- Overrides:
installUIin classComponentUI
-
uninstallUI
- Overrides:
uninstallUIin classComponentUI
-
installDefaults
protected void installDefaults()Installs default parameters on the associated ribbon band. -
installComponents
protected void installComponents()Installs subcomponents on the associated ribbon band. -
createExpandButton
Creates the expand button for the associated ribbon band.- Returns:
- Expand button for the associated ribbon band.
-
syncExpandButtonIcon
protected void syncExpandButtonIcon() -
installListeners
protected void installListeners()Installs listeners on the associated ribbon band. -
configureExpandButton
protected void configureExpandButton() -
uninstallDefaults
protected void uninstallDefaults()Uninstalls default parameters from the associated ribbon band. -
uninstallComponents
protected void uninstallComponents()Uninstalls components from the associated ribbon band. -
uninstallListeners
protected void uninstallListeners()Uninstalls listeners from the associated ribbon band. -
unconfigureExpandButton
protected void unconfigureExpandButton() -
createLayoutManager
Invoked byinstallUIto create a layout manager object to manage theJCommandButtonStrip.- Returns:
- a layout manager object
-
update
- Overrides:
updatein classComponentUI
-
paint
- Overrides:
paintin classComponentUI
-
paintBandTitle
Paints band title pane.- Parameters:
g- Graphics context.titleRectangle- Rectangle for the title pane.title- Title string.
-
paintBandTitleBackground
Paints band title pane.- Parameters:
g- Graphics context.titleRectangle- Rectangle for the title pane.title- Title string.
-
setRolloverAmount
public void setRolloverAmount(float rolloverAmount) -
paintBandBackground
Paints band background.- Parameters:
graphics- Graphics context.toFill- Rectangle for the background.
-
getRolloverAmount
public float getRolloverAmount()- Specified by:
getRolloverAmountin classRibbonBandUI
-
getBandTitleHeight
public int getBandTitleHeight()Returns the height of the ribbon band title area.- Specified by:
getBandTitleHeightin classRibbonBandUI- Returns:
- The height of the ribbon band title area.
-
getPreferredCollapsedWidth
public int getPreferredCollapsedWidth()- Specified by:
getPreferredCollapsedWidthin classRibbonBandUI
-
trackMouseCrossing
public void trackMouseCrossing(boolean isMouseIn) - Specified by:
trackMouseCrossingin classRibbonBandUI
-
getExpandButton
Deprecated.This method is for unit tests only and should not be called by the application code.- Returns:
- The expand button of the matching ribbon band.
-
getCollapsedButton
Deprecated.This method is for unit tests only and should not be called by the application code.- Returns:
- The expand button of the matching ribbon band.
-