窗口体居中:
import javax.swing.JFrame;
public class Jproject1 {
public static void main(String args[]){
JFrame frame = new JFrame();
frame.setSize(300,100);
frame.setVisible(true);
frame.setLocationRelativeTo(null);//窗口体居中
}
}
窗口体居中:
import javax.swing.JFrame;
public class Jproject1 {
public static void main(String args[]){
JFrame frame = new JFrame();
frame.setSize(300,100);
frame.setVisible(true);
frame.setLocationRelativeTo(null);//窗口体居中
}
}