org.pushingpixels.flamingo.internal.ui.ribbon
Class BasicRibbonComponentUI

java.lang.Object
  extended by javax.swing.plaf.ComponentUI
      extended by org.pushingpixels.flamingo.internal.ui.ribbon.RibbonComponentUI
          extended by org.pushingpixels.flamingo.internal.ui.ribbon.BasicRibbonComponentUI

public class BasicRibbonComponentUI
extends RibbonComponentUI


Nested Class Summary
protected  class BasicRibbonComponentUI.ExtComponentLayout
           
 
Field Summary
protected  javax.swing.JLabel captionLabel
           
protected  ResizableIcon disabledIcon
           
protected  java.beans.PropertyChangeListener propertyChangeListener
           
protected  JRibbonComponent ribbonComponent
          The associated ribbon component.
 
Constructor Summary
BasicRibbonComponentUI()
           
 
Method Summary
protected  ResizableIcon createDisabledIcon()
           
protected  java.awt.LayoutManager createLayoutManager()
           
static javax.swing.plaf.ComponentUI createUI(javax.swing.JComponent c)
           
 java.awt.Point getKeyTipAnchorCenterPoint()
           
protected  int getLayoutGap()
           
 java.awt.Dimension getPreferredSize(RibbonElementPriority priority)
           
protected  void installComponents()
          Installs subcomponents on the associated ribbon component.
protected  void installDefaults()
          Installs default parameters on the associated ribbon component.
protected  void installListeners()
          Installs listeners on the associated ribbon component.
 void installUI(javax.swing.JComponent c)
           
protected  boolean isCaptionVisible(RibbonElementPriority displayPriority)
           
protected  boolean isIconVisible(RibbonElementPriority displayPriority)
           
 void paint(java.awt.Graphics g, javax.swing.JComponent c)
           
protected  void paintIcon(java.awt.Graphics g, JRibbonComponent ribbonComp, javax.swing.Icon icon, int x, int y)
           
protected  void uninstallComponents()
          Uninstalls components from the associated ribbon component.
protected  void uninstallDefaults()
          Uninstalls default parameters from the associated ribbon component.
protected  void uninstallListeners()
          Uninstalls listeners from the associated ribbon component.
 void uninstallUI(javax.swing.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

ribbonComponent

protected JRibbonComponent ribbonComponent
The associated ribbon component.


captionLabel

protected javax.swing.JLabel captionLabel

propertyChangeListener

protected java.beans.PropertyChangeListener propertyChangeListener

disabledIcon

protected ResizableIcon disabledIcon
Constructor Detail

BasicRibbonComponentUI

public BasicRibbonComponentUI()
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

installDefaults

protected void installDefaults()
Installs default parameters on the associated ribbon component.


installComponents

protected void installComponents()
Installs subcomponents on the associated ribbon component.


installListeners

protected void installListeners()
Installs listeners on the associated ribbon component.


uninstallDefaults

protected void uninstallDefaults()
Uninstalls default parameters from the associated ribbon component.


uninstallComponents

protected void uninstallComponents()
Uninstalls components from the associated ribbon component.


uninstallListeners

protected void uninstallListeners()
Uninstalls listeners from the associated ribbon component.


getKeyTipAnchorCenterPoint

public java.awt.Point getKeyTipAnchorCenterPoint()
Specified by:
getKeyTipAnchorCenterPoint in class RibbonComponentUI

createLayoutManager

protected java.awt.LayoutManager createLayoutManager()

paint

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

paintIcon

protected void paintIcon(java.awt.Graphics g,
                         JRibbonComponent ribbonComp,
                         javax.swing.Icon icon,
                         int x,
                         int y)

getLayoutGap

protected int getLayoutGap()

createDisabledIcon

protected ResizableIcon createDisabledIcon()

isIconVisible

protected boolean isIconVisible(RibbonElementPriority displayPriority)

isCaptionVisible

protected boolean isCaptionVisible(RibbonElementPriority displayPriority)

getPreferredSize

public java.awt.Dimension getPreferredSize(RibbonElementPriority priority)
Specified by:
getPreferredSize in class RibbonComponentUI