userbutton.java
字号:
package piy.usercomponent;
import java.awt.*;
import javax.swing.JButton;
import piy.UserComponent;
/**
* A button object which the user can add to their windows. Properties include
* the text on the button.
* @author David Vivash
* @version 1.0, 20/11/00
*/
public class UserButton extends JButton implements UserComponent
{
public UserButton() {
setText("Button");
}
public String getText() { return super.getText(); }
public void setText(String text) { super.setText(text); }
public Color getBackground() { return super.getBackground(); }
public void setBackground(Color c) { super.setBackground(c); }
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -