类JFraemDemo,用于显示窗体
package com.arthur.exercise_0703;
import java.awt.Label;
import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JTextField;
public class JFrameDemo extends JFrame{
JTextField textField = new JTextField(20);
Label label = new Label("请输入一个1000以内的整数!");
JButton buttonguess = new JButton("猜");
JButton buttonrwork = new JButton("重新来过");
JButton buttonexitgame = new
JButton("退出游戏");
public void shouFrame(){
this.setLayout(null);
this.setBounds(600, 300, 300,
250);
textField.setBounds(5, 5, 285,
30);
label.setBounds(5, 70, 300,
30);
buttonguess.setBounds(10, 150,
70, 40);
buttonrwork.setBounds(85, 150,
100, 40);
buttone