//*******************************************************************
//
//   Grid.java          In Text          Applet
//
//   Authors:  Lewis and Loftus
//
//   Classes:  Grid
//
//*******************************************************************

import java.applet.Applet;
import java.awt.*;

//-------------------------------------------------------------------
//
//  Class Grid demonstrates the grid layout manager.
//
//  Methods:
//
//     public void init()
//
//-------------------------------------------------------------------

public class Grid extends Applet {

   private Button button1 = new Button ("I");
   private Button button2 = new Button ("think");
   private Button button3 = new Button ("therefore");
   private Button button4 = new Button ("I");
   private Button button5 = new Button ("am");

   //===========================================================
   //  Creates a new grid layout and adds five buttons to it.
   //===========================================================
   public void init() {

      setLayout (new GridLayout(2,3));

      add (button1);
      add (button2);
      add (button3);
      add (button4);
      add (button5);

      //      setVisible(true);
      show(true);
   }  // method init

}  // class Grid


