GUI简单
class B extends JFrame implements ActionListener{
JTextField t1;
JButton b1;
public B(){
t1 = new JTextField(10);
b1 = new JButton(“123”);
setSize(500,500);
setVisible(true);
setDefaultCloseOperation(DISPOSE_ON_CLOSE);
setLayout(new FlowLayout());
add(t1);
原创
2022-01-03 10:53:09 ·
110 阅读 ·
0 评论