Example #1
0
 public static void main(String[] args) {
   Plot2D test = new Plot2D();
   JFrame f = new JFrame();
   f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
   f.add(test.getContent());
   f.add(test.getUIPanel(), "Last");
   f.setSize(400, 400);
   f.setLocation(50, 50);
   f.setVisible(true);
 }
 public static void main(String[] args) {
   JFrame f = new JFrame();
   f.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
   f.add(new GraphingData());
   f.setSize(515, 310);
   f.setLocation(0, 420);
   f.setVisible(true);
 }
Example #3
0
 public static void main(String[] args) {
   JFrame f = new JFrame();
   f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
   f.getContentPane().add(new DrawingATree());
   f.setSize(400, 400);
   f.setLocation(200, 200);
   f.setVisible(true);
 }
Example #4
0
 public static void createAndShowGUI() {
   try {
     UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
   } catch (ClassNotFoundException
       | InstantiationException
       | IllegalAccessException
       | UnsupportedLookAndFeelException ex) {
     ex.printStackTrace();
   }
   JFrame frame = new JFrame("@title@");
   frame.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
   frame.getContentPane().add(new MainPanel());
   frame.pack();
   frame.setLocationRelativeTo(null);
   frame.setVisible(true);
 }