Java JFrame Window (JFrame size - 300x280) |
import javax.swing.JFrame;
public class MyClass extends JFrame{
public MyClass(){
setSize(800,600);
setTitle("JavaJFrameWindow1");
setDefaultCloseOperation(EXIT_ON_CLOSE);
setVisible(true);
}
public static void main(String[] args){
new MyClass();
}
}
You can modify the window by adding or changing the JFrame's attributes in the constructor.
0 comments:
Post a Comment