个人信息

 
 

package 个人信息显示界面;
import java.awt.*;
public class LoginFrame extends Frame
{
public LoginFrame ()
    {
     super("个人信息");
     this.setSize(250,250);//设计组件的尺寸
     this.setLocation(800,600);//设计组件显示的位置
     this.setBackground(Color.gray);//设计背景颜色
     this.setLayout(new FlowLayout());//设计容器为流布局,居中
     this.add(new Label("姓名"));
     this.add(new TextField("佳人",20));
     this.add(new Label("性别"));
     this.add(new TextField("女",20));
     this.add(new Label("爱好"));
     this.add(new TextField("吃,喝。玩。乐",20));
     this.add(new Label("年龄"));
     this.add(new TextField("2",20));
     this.add(new Button("OK"));
     this.setVisible(true);
     
    }
     public static void main(String args[]){new LoginFrame();}

}
posted @ 2018-06-04 22:11  孔得秀  阅读(137)  评论(0编辑  收藏  举报