frame.setLocationRelativeTo(null);//窗体居中显示
frame.setVisible(true);
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
}
程序的效果图:
本文出自 “IT的点点滴滴” 博客