JavaTM 2 Platform
Std. Ed. v1.3

javax.swing.plaf.basic
Class BasicButtonUI

java.lang.Object
  |
  +--javax.swing.plaf.ComponentUI
        |
        +--javax.swing.plaf.ButtonUI
              |
              +--javax.swing.plaf.basic.BasicButtonUI
Direct Known Subclasses:
BasicToggleButtonUI, MetalButtonUI

public class BasicButtonUI
extends ButtonUI

BasicButton implementation


Field Summary
protected  int defaultTextIconGap
           
protected  int defaultTextShiftOffset
           
 
Constructor Summary
BasicButtonUI()
           
 
Method Summary
protected  void clearTextShiftOffset()
           
protected  BasicButtonListener createButtonListener(AbstractButton b)
           
static ComponentUI createUI(JComponent c)
           
 int getDefaultTextIconGap(AbstractButton b)
           
 Dimension getMaximumSize(JComponent c)
           
 Dimension getMinimumSize(JComponent c)
           
 Dimension getPreferredSize(JComponent c)
           
protected  String getPropertyPrefix()
           
protected  int getTextShiftOffset()
           
protected  void installDefaults(AbstractButton b)
           
protected  void installKeyboardActions(AbstractButton b)
           
protected  void installListeners(AbstractButton b)
           
 void installUI(JComponent c)
           
 void paint(Graphics g, JComponent c)
           
protected  void paintButtonPressed(Graphics g, AbstractButton b)
           
protected  void paintFocus(Graphics g, AbstractButton b, Rectangle viewRect, Rectangle textRect, Rectangle iconRect)
           
protected  void paintIcon(Graphics g, JComponent c, Rectangle iconRect)
           
protected  void paintText(Graphics g, JComponent c, Rectangle textRect, String text)
           
protected  void setTextShiftOffset()
           
protected  void uninstallDefaults(AbstractButton b)
           
protected  void uninstallKeyboardActions(AbstractButton b)
           
protected  void uninstallListeners(AbstractButton b)
           
 void uninstallUI(JComponent c)
           
 
Methods inherited from class javax.swing.plaf.ComponentUI
contains, getAccessibleChild, getAccessibleChildrenCount, update
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

defaultTextIconGap

protected int defaultTextIconGap

defaultTextShiftOffset

protected int defaultTextShiftOffset
Constructor Detail

BasicButtonUI

public BasicButtonUI()
Method Detail

createUI

public static ComponentUI createUI(JComponent c)

getPropertyPrefix

protected String getPropertyPrefix()

installUI

public void installUI(JComponent c)
Overrides:
installUI in class ComponentUI

installDefaults

protected void installDefaults(AbstractButton b)

installListeners

protected void installListeners(AbstractButton b)

installKeyboardActions

protected void installKeyboardActions(AbstractButton b)

uninstallUI

public void uninstallUI(JComponent c)
Overrides:
uninstallUI in class ComponentUI

uninstallKeyboardActions

protected void uninstallKeyboardActions(AbstractButton b)

uninstallListeners

protected void uninstallListeners(AbstractButton b)

uninstallDefaults

protected void uninstallDefaults(AbstractButton b)

createButtonListener

protected BasicButtonListener createButtonListener(AbstractButton b)

getDefaultTextIconGap

public int getDefaultTextIconGap(AbstractButton b)

paint

public void paint(Graphics g,
                  JComponent c)
Overrides:
paint in class ComponentUI

paintIcon

protected void paintIcon(Graphics g,
                         JComponent c,
                         Rectangle iconRect)

paintText

protected void paintText(Graphics g,
                         JComponent c,
                         Rectangle textRect,
                         String text)

paintFocus

protected void paintFocus(Graphics g,
                          AbstractButton b,
                          Rectangle viewRect,
                          Rectangle textRect,
                          Rectangle iconRect)

paintButtonPressed

protected void paintButtonPressed(Graphics g,
                                  AbstractButton b)

clearTextShiftOffset

protected void clearTextShiftOffset()

setTextShiftOffset

protected void setTextShiftOffset()

getTextShiftOffset

protected int getTextShiftOffset()

getMinimumSize

public Dimension getMinimumSize(JComponent c)
Overrides:
getMinimumSize in class ComponentUI

getPreferredSize

public Dimension getPreferredSize(JComponent c)
Overrides:
getPreferredSize in class ComponentUI

getMaximumSize

public Dimension getMaximumSize(JComponent c)
Overrides:
getMaximumSize in class ComponentUI

JavaTM 2 Platform
Std. Ed. v1.3

Submit a bug or feature
For further API reference and developer documentation, see Java 2 SDK SE Developer Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.

Java, Java 2D, and JDBC are trademarks or registered trademarks of Sun Microsystems, Inc. in the US and other countries.
Copyright 1993-2000 Sun Microsystems, Inc. 901 San Antonio Road
Palo Alto, California, 94303, U.S.A. All Rights Reserved.