//TestPane.java package myprojects.testpane; import java.awt.*; import java.awt.event.*; class TestPane extends Frame { public TestPane() { addWindowListener(new WindowAdapter() { public void windowClosing(WindowEvent e) { dispose(); System.exit(0); } }); TextArea ta=new TextArea("",10,50,TextArea.SCROLLBARS_NONE); ScrollPane sp=new ScrollPane(); sp.add(ta); add(sp); } public static void main(String args[]) { System.out.println("Starting TestPane..."); TestPane mainFrame = new TestPane(); mainFrame.setSize(200, 200); mainFrame.setTitle("TestPane"); mainFrame.setVisible(true); } }