|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjavax.swing.plaf.ComponentUI
javax.swing.plaf.ButtonUI
javax.swing.plaf.basic.BasicButtonUI
javax.swing.plaf.metal.MetalButtonUI
com.jgoodies.looks.plastic.PlasticButtonUI
public class PlasticButtonUI
The JGoodies Plastic L&F implementation of ButtonUI.
It differs from the superclass MetalButtonUI in that
it can add a pseudo 3D effect, and that it listens to the
jgoodies.isNarrow property to choose an appropriate margin.
Options.IS_NARROW_KEY| Field Summary |
|---|
| Fields inherited from class javax.swing.plaf.metal.MetalButtonUI |
|---|
disabledTextColor, focusColor, selectColor |
| Fields inherited from class javax.swing.plaf.basic.BasicButtonUI |
|---|
defaultTextIconGap, defaultTextShiftOffset |
| Constructor Summary | |
|---|---|
PlasticButtonUI()
|
|
| Method Summary | |
|---|---|
static javax.swing.plaf.ComponentUI |
createUI(javax.swing.JComponent b)
|
void |
installDefaults(javax.swing.AbstractButton b)
Installs defaults and honors the client property isNarrow. |
void |
installListeners(javax.swing.AbstractButton b)
Installs an extra listener for a change of the isNarrow property. |
protected boolean |
is3D(javax.swing.AbstractButton b)
Checks and answers if this button shall use a pseudo 3D effect. |
protected boolean |
isToolBarButton(javax.swing.AbstractButton b)
Checks and answers if this is button is in a tool bar. |
protected void |
paintFocus(java.awt.Graphics g,
javax.swing.AbstractButton b,
java.awt.Rectangle viewRect,
java.awt.Rectangle textRect,
java.awt.Rectangle iconRect)
Paints the focus with close to the button's border. |
void |
uninstallListeners(javax.swing.AbstractButton b)
Uninstalls the extra listener for a change of the isNarrow property. |
void |
update(java.awt.Graphics g,
javax.swing.JComponent c)
|
| Methods inherited from class javax.swing.plaf.metal.MetalButtonUI |
|---|
createButtonListener, getDisabledTextColor, getFocusColor, getSelectColor, paintButtonPressed, paintText, uninstallDefaults |
| Methods inherited from class javax.swing.plaf.basic.BasicButtonUI |
|---|
clearTextShiftOffset, getBaseline, getBaselineResizeBehavior, getDefaultTextIconGap, getMaximumSize, getMinimumSize, getPreferredSize, getPropertyPrefix, getTextShiftOffset, installKeyboardActions, installUI, paint, paintIcon, paintText, setTextShiftOffset, uninstallKeyboardActions, uninstallUI |
| Methods inherited from class javax.swing.plaf.ComponentUI |
|---|
contains, getAccessibleChild, getAccessibleChildrenCount |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public PlasticButtonUI()
| Method Detail |
|---|
public static javax.swing.plaf.ComponentUI createUI(javax.swing.JComponent b)
public void installDefaults(javax.swing.AbstractButton b)
isNarrow.
installDefaults in class javax.swing.plaf.metal.MetalButtonUIpublic void installListeners(javax.swing.AbstractButton b)
installListeners in class javax.swing.plaf.basic.BasicButtonUIpublic void uninstallListeners(javax.swing.AbstractButton b)
uninstallListeners in class javax.swing.plaf.basic.BasicButtonUI
public void update(java.awt.Graphics g,
javax.swing.JComponent c)
update in class javax.swing.plaf.metal.MetalButtonUI
protected void paintFocus(java.awt.Graphics g,
javax.swing.AbstractButton b,
java.awt.Rectangle viewRect,
java.awt.Rectangle textRect,
java.awt.Rectangle iconRect)
paintFocus in class javax.swing.plaf.metal.MetalButtonUIprotected boolean isToolBarButton(javax.swing.AbstractButton b)
b - the button to check
protected boolean is3D(javax.swing.AbstractButton b)
b - the button to check
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||