|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.swing.plaf.ComponentUI
org.pushingpixels.flamingo.internal.ui.ribbon.RibbonGalleryUI
org.pushingpixels.flamingo.internal.ui.ribbon.BasicRibbonGalleryUI
public class BasicRibbonGalleryUI
Basic UI for ribbon gallery JRibbonGallery
.
Nested Class Summary | |
---|---|
protected static class |
BasicRibbonGalleryUI.ExpandCommandButton
|
protected static class |
BasicRibbonGalleryUI.JButtonStripUIResource
Button strip as a UI resource. |
Field Summary | |
---|---|
protected JCommandButtonStrip |
buttonStrip
Contains the scroll down, scroll up and show popup buttons. |
protected BasicRibbonGalleryUI.ExpandCommandButton |
expandActionButton
The button that shows the associated popup gallery. |
protected ActionListener |
expandListener
Listener on the gallery expand button. |
protected int |
firstVisibleButtonIndex
The index of the first visible button. |
protected Insets |
margin
Ribbon gallery margin. |
protected PopupPanelManager.PopupListener |
popupListener
Listener on the PopupPanelManager changes to sync the
JRibbonGallery.setShowingPopupPanel(boolean) once the popup
gallery is dismissed by the user. |
protected PropertyChangeListener |
propertyChangeListener
Property change listener. |
protected JRibbonGallery |
ribbonGallery
The associated ribbon gallery. |
protected JCommandButton |
scrollDownButton
The button that scrolls down the associated ribbonGallery . |
protected ActionListener |
scrollDownListener
Listener on the gallery scroll-down button. |
protected JCommandButton |
scrollUpButton
The button that scrolls up the associated ribbonGallery . |
protected ActionListener |
scrollUpListener
Listener on the gallery scroll-up button. |
protected int |
visibleButtonRowNumber
|
protected int |
visibleButtonsInEachRow
The count of visible buttons. |
Constructor Summary | |
---|---|
BasicRibbonGalleryUI()
|
Method Summary | |
---|---|
protected BasicRibbonGalleryUI.ExpandCommandButton |
createExpandButton()
Creates the expand button. |
protected LayoutManager |
createLayoutManager()
Invoked by installUI to create a layout manager object to
manage the JCommandButtonStrip . |
protected JCommandButton |
createScrollDownButton()
Creates the scroll-down button. |
protected JCommandButton |
createScrollUpButton()
Creates the scroll-up button. |
static ComponentUI |
createUI(JComponent c)
|
protected int |
getLayoutGap()
Returns the layout gap for the controls in the associated ribbon gallery. |
int |
getPreferredWidth(int buttonCount,
int availableHeight)
Returns the preferred width of the ribbon gallery for the specified parameters. |
protected void |
installComponents()
Installs subcomponents on the associated ribbon gallery. |
protected void |
installDefaults()
Installs defaults on the associated ribbon gallery. |
protected void |
installListeners()
Installs listeners on the associated ribbon gallery. |
void |
installUI(JComponent c)
|
void |
paint(Graphics g,
JComponent c)
|
protected void |
paintRibbonGalleryBorder(Graphics graphics)
Paints ribbon gallery border. |
protected void |
scrollOneRowDown()
Scrolls the contents of this ribbon gallery one row down. |
protected void |
scrollOneRowUp()
Scrolls the contents of this ribbon gallery one row up. |
protected void |
scrollToSelected()
Scrolls the contents of this ribbon gallery to reveal the currently selected button. |
protected void |
syncExpandKeyTip()
|
protected void |
uninstallComponents()
Uninstalls subcomponents from the associated ribbon gallery. |
protected void |
uninstallDefaults()
Uninstalls defaults from the associated ribbon gallery. |
protected void |
uninstallListeners()
Uninstalls listeners from the associated ribbon gallery. |
void |
uninstallUI(JComponent c)
|
Methods inherited from class javax.swing.plaf.ComponentUI |
---|
contains, getAccessibleChild, getAccessibleChildrenCount, getBaseline, getBaselineResizeBehavior, getMaximumSize, getMinimumSize, getPreferredSize, update |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected JRibbonGallery ribbonGallery
protected int firstVisibleButtonIndex
protected int visibleButtonsInEachRow
protected int visibleButtonRowNumber
protected JCommandButton scrollDownButton
ribbonGallery
.
protected JCommandButton scrollUpButton
ribbonGallery
.
protected BasicRibbonGalleryUI.ExpandCommandButton expandActionButton
protected JCommandButtonStrip buttonStrip
scrollDownButton
,
scrollUpButton
,
expandActionButton
protected ActionListener scrollDownListener
protected ActionListener scrollUpListener
protected ActionListener expandListener
protected PopupPanelManager.PopupListener popupListener
PopupPanelManager
changes to sync the
JRibbonGallery.setShowingPopupPanel(boolean)
once the popup
gallery is dismissed by the user.
protected PropertyChangeListener propertyChangeListener
protected Insets margin
Constructor Detail |
---|
public BasicRibbonGalleryUI()
Method Detail |
---|
public static ComponentUI createUI(JComponent c)
public void installUI(JComponent c)
installUI
in class ComponentUI
protected void installComponents()
protected JCommandButton createScrollDownButton()
protected JCommandButton createScrollUpButton()
protected BasicRibbonGalleryUI.ExpandCommandButton createExpandButton()
protected void uninstallComponents()
protected void installDefaults()
protected void uninstallDefaults()
protected void installListeners()
protected void uninstallListeners()
public void uninstallUI(JComponent c)
uninstallUI
in class ComponentUI
protected LayoutManager createLayoutManager()
installUI
to create a layout manager object to
manage the JCommandButtonStrip
.
public void paint(Graphics g, JComponent c)
paint
in class ComponentUI
protected void paintRibbonGalleryBorder(Graphics graphics)
graphics
- Graphics context.toFill
- Rectangle for the background.protected int getLayoutGap()
public int getPreferredWidth(int buttonCount, int availableHeight)
buttonCount
- Button count.availableHeight
- Available height in pixels.
protected void scrollOneRowDown()
protected void scrollOneRowUp()
protected void scrollToSelected()
protected void syncExpandKeyTip()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |