~cpp JFrame frame = new JFrame(); frame.setSize(400,400); Dimension d = Toolkit.getDefaultToolkit().getScreenSize(); frame.setLocation((d.width-frame.getWidth())/2, (d.height-frame.getHeight())/2); frame.setVisible(true);
~cpp page.getContentPane().setLayout(null);