Make your own free website on Tripod.com
import java.awt.*;
import java.applet.*;
import tab.TabPanels;
public class TabDemo extends Applet
{
    public void init()
    {
	setLayout(new BorderLayout());
	setSize(426,266);
	Panel tabPanels[];
        String tabTitles[] = {"Tab one","Tab two","Tab three","Tab four","Tab five","Tab six"};
        TabPanels tab = new TabPanels();
        add("Center",tab);
        tabPanels = new Panel[tabTitles.length];
        for (int i=0; i<tabPanels.length; i++) {
            tabPanels[i] = new Panel(new BorderLayout());
            tabPanels[i].add("Center",new Button("Panel "+i));
            tab.addTab(tabTitles[i],tabPanels[i]);
        }
    }
}