-
23일 차 Swing의 기본 JFrame삼성SDS_멀티캠퍼스/Java 2015. 10. 12. 09:37반응형
import javax.swing.JButton;
import javax.swing.JFrame;
class MyFrame extends JFrame {
public MyFrame() {
JButton button = new JButton("버튼");
this.add(button);
this.setSize(300, 200);
this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
this.setTitle("Wooki");
this.setVisible(true);
}
}
public class Test2 {
public static void main(String[] args) {
MyFrame f = new MyFrame();
}
}
반응형'삼성SDS_멀티캠퍼스 > Java' 카테고리의 다른 글
23일 차 Swing 버튼2개를 만들어서 클릭시 텍스트 변경 (0) 2015.10.12 23일 차 Swing 버튼클릭시 텍스트 변하게(ActionListener) (0) 2015.10.12 22일 차 SVN 처음부터 끝까지! (下편) (0) 2015.10.08 22일 차 SVN 처음부터 끝까지! (上편) (0) 2015.10.08 22일 차 SVN 기본 생성 (0) 2015.10.08