import java.awt.*; import java.awt.event.*; import javax.swing.*; class Example0 extends JFrame { public Example0() { Container content_pane = this.getContentPane(); content_pane.setLayout(new FlowLayout()); JButton button = new JButton("Hello World"); content_pane.add(button); setSize(300,300); setVisible(true); } public static void main(String argv[]) { try { //UIManager.setLookAndFeel("javax.swing.plaf.metal.MetalLookAndFeel"); //UIManager.setLookAndFeel("com.sun.java.swing.plaf.windows.WindowsLookAndFeel"); UIManager.setLookAndFeel("com.sun.java.swing.plaf.motif.MotifLookAndFeel"); //UIManager.setLookAndFeel("javax.swing.plaf.mac.MacLookAndFeel"); } catch(Exception e) { } new Example0(); } }