ButtonNameButton
DescriptionThe Button is the familiar labeled button object. It inherits most of its functionality from Component. For example, to change the font of the Button, you would use Component's setFont() method. The Button sends java.awt.event.ActionEvent objects to its listeners when it is pressed. Class Definition
public class java.awt.Button extends java.awt.Component { // Constructors public Button(); public Button (String label); // Instance Methods public void addActionListener (ActionListener l); public void addNotify(); public String getActionCommand(); public String getLabel(); public void removeActionListener (ActionListener l); public void setActionCommand (String command); public synchronized void setLabel (String label); // Protected Instance Methods protected String paramString(); protected void processActionEvent (ActionEvent e); protected void processEvent (AWTEvent e); } ConstructorsButtonpublic Button()
public Button (String label)
Instance MethodsaddActionListenerpublic void addActionListener (ActionListener l)
addNotifypublic void addNotify()
getActionCommandpublic String getActionCommand()
getLabelpublic String getLabel()
removeActionListenerpublic void removeActionListener (ActionListener l)
setActionCommandpublic void setActionCommand (String command)
setLabelpublic synchronized void setLabel (String label)
Protected Instance MethodsparamStringprotected String paramString()
processActionEventprotected void processActionEvent (ActionEvent e)
processEventprotected void processEvent (AWTEvent e)
See AlsoActionListener, Component, String |
|