org.jvnet.flamingo.ribbon.ui
Class BasicRibbonUI

java.lang.Object
  extended by javax.swing.plaf.ComponentUI
      extended by org.jvnet.flamingo.ribbon.ui.RibbonUI
          extended by org.jvnet.flamingo.ribbon.ui.BasicRibbonUI

public class BasicRibbonUI
extends RibbonUI

Basic UI for ribbon JRibbon.

Author:
Kirill Grouchnikov

Field Summary
static java.lang.String IS_USING_TITLE_PANE
          Client property marking the ribbon component to indicate whether the task bar and contextual task group headers should be shown on the title pane of the window.
 
Constructor Summary
BasicRibbonUI()
          Creates a new basic ribbon UI delegate.
 
Method Summary
static javax.swing.plaf.ComponentUI createUI(javax.swing.JComponent c)
           
 java.awt.Rectangle getContextualTaskGroupBounds(RibbonContextualTaskGroup group)
          Returns the bounds of the specified contextual task group.
 int getTaskbarHeight()
          Returns the height of the taskbar area.
 int getTaskToggleButtonHeight()
          Returns the height of the task toggle button area.
 java.util.Map<RibbonTask,JRibbonTaskToggleButton> getTaskToggleButtons()
           
 void handleMouseWheelEvent(java.awt.event.MouseWheelEvent e)
           
 void installUI(javax.swing.JComponent c)
           
 boolean isShowingScrollsForBands()
           
 boolean isShowingScrollsForTaskToggleButtons()
           
 void paint(java.awt.Graphics g, javax.swing.JComponent c)
           
 void uninstallUI(javax.swing.JComponent c)
           
 void update(java.awt.Graphics g, javax.swing.JComponent c)
           
 
Methods inherited from class javax.swing.plaf.ComponentUI
contains, getAccessibleChild, getAccessibleChildrenCount, getBaseline, getBaselineResizeBehavior, getMaximumSize, getMinimumSize, getPreferredSize
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

IS_USING_TITLE_PANE

public static final java.lang.String IS_USING_TITLE_PANE
Client property marking the ribbon component to indicate whether the task bar and contextual task group headers should be shown on the title pane of the window. This is only relevant for the JRibbonFrame.

See Also:
Constant Field Values
Constructor Detail

BasicRibbonUI

public BasicRibbonUI()
Creates a new basic ribbon UI delegate.

Method Detail

createUI

public static javax.swing.plaf.ComponentUI createUI(javax.swing.JComponent c)

installUI

public void installUI(javax.swing.JComponent c)
Overrides:
installUI in class javax.swing.plaf.ComponentUI

uninstallUI

public void uninstallUI(javax.swing.JComponent c)
Overrides:
uninstallUI in class javax.swing.plaf.ComponentUI

update

public void update(java.awt.Graphics g,
                   javax.swing.JComponent c)
Overrides:
update in class javax.swing.plaf.ComponentUI

paint

public void paint(java.awt.Graphics g,
                  javax.swing.JComponent c)
Overrides:
paint in class javax.swing.plaf.ComponentUI

getContextualTaskGroupBounds

public java.awt.Rectangle getContextualTaskGroupBounds(RibbonContextualTaskGroup group)
Description copied from class: RibbonUI
Returns the bounds of the specified contextual task group.

Specified by:
getContextualTaskGroupBounds in class RibbonUI
Parameters:
group - Contextual task group.
Returns:
The bounds of the specified contextual task group.

getTaskbarHeight

public int getTaskbarHeight()
Returns the height of the taskbar area.

Returns:
The height of the taskbar area.

getTaskToggleButtonHeight

public int getTaskToggleButtonHeight()
Returns the height of the task toggle button area.

Returns:
The height of the task toggle button area.

isShowingScrollsForTaskToggleButtons

public boolean isShowingScrollsForTaskToggleButtons()
Specified by:
isShowingScrollsForTaskToggleButtons in class RibbonUI

isShowingScrollsForBands

public boolean isShowingScrollsForBands()
Specified by:
isShowingScrollsForBands in class RibbonUI

getTaskToggleButtons

public java.util.Map<RibbonTask,JRibbonTaskToggleButton> getTaskToggleButtons()

handleMouseWheelEvent

public void handleMouseWheelEvent(java.awt.event.MouseWheelEvent e)
Specified by:
handleMouseWheelEvent in class RibbonUI