FileDocCategorySizeDatePackage
Cubic.javaAPI DocExample7044Tue Dec 12 19:00:00 GMT 2000None

Cubic

public class Cubic extends JApplet

Fields Summary
protected static JLabel
label
CubicPanel
cubicPanel
Constructors Summary
Methods Summary
public voidinit()

	//Initialize the layout.
        getContentPane().setLayout(new BorderLayout());
        cubicPanel = new CubicPanel();
        cubicPanel.setBackground(Color.white);
	getContentPane().add(cubicPanel);
	label = new JLabel("Drag the points to adjust the curve.");
	getContentPane().add("South", label);
    
public static voidmain(java.lang.String[] s)

        JFrame f = new JFrame("Cubic");
        CubicPanel cubicPanel = new CubicPanel();
        f.addWindowListener(new WindowAdapter() {
            public void windowClosing(WindowEvent e) {System.exit(0);}
        });
        JApplet applet = new Cubic();
        f.getContentPane().add(applet, BorderLayout.CENTER);
        applet.init();
        f.setSize(new Dimension(350,250));
        f.setVisible(true);