GT Computing Home Page

GT Computing Home Page

The Seaside Applet

Here's a listing of this simple applet:

//	Seaside.java

import java.applet.*;
import linguist.quickshow.*;

public class Seaside extends Applet
{
	public void init()
	{
		super.init();

		setLayout(null);
		Stage stage=new SeasideStage();
		setSize(stage.WIDTH,stage.HEIGHT);
		add(stage);
		show();
    }
}

The applet is very simple. After initalizing itself it creates a SeasideStage - a subclass of Stage, sets itself to the size of the Stage and adds the Stage. Since the latter is a Canvas you can use it in any way you might use a Canvas.