/********************************************************************
Class button_panel
 --Puts buttons onto a panel so they can be added as a group to the 
game board.

Authors: Kristi Garner, Mary Garland    
CS406: Java and Internet Programming
*******************************************************************/
import java.awt.*;
import java.awt.image.*;
import java.awt.event.*;
import java.util.*;
import java.applet.*;
import java.net.*;
import java.applet.Applet;

class button_panel extends Panel 
{  


  private Image panelimage;		// the image on the panel
		// this particular letter's score
  private int gridx, gridy;		// this panel's row, col location
  private Button helpButton, aboutButton, quitButton;
  private Button doneButton, chalButton, acceptButton;
  private Button undoButton;
  Font bfont = new Font("Arial",Font.BOLD, 24);
	Color orchid1 = new Color (155,168,254);
	Color orchid2 = new Color(242,214,255);
	Color orchid3 = new Color (104,34,139);
	Color slblue = new Color (72,61,139);

  /*******************************************************************/
  // constructor button_panel
  public button_panel(String a, String b) { 

	GridLayout layout = new GridLayout(2,1,20,20);
	this.setLayout(layout);
	this.setBackground (Color.cyan);
	if ( a == "done"){
		doneButton = new Button ("Done");
		doneButton.setBackground(orchid2);
		doneButton.setForeground(orchid3);
		doneButton.setFont(bfont);
		this.add(doneButton);
	}
	if (b == "undo"){
		undoButton = new Button ("Undo");
		undoButton.setBackground(orchid2);
		undoButton.setForeground(orchid3);
		undoButton.setFont(bfont);

		this.add(undoButton);
	}
	if (a == "challenge") {
		chalButton = new Button ("Challenge");
		//chalButton.addActionListener (this);
		chalButton.setBackground(orchid1);
		chalButton.setForeground(orchid3);
		chalButton.setFont(bfont);
		this.add(chalButton);
	}
	if (b == "accept") {
		acceptButton = new Button ("Accept");
		acceptButton.setBackground(orchid1);
		acceptButton.setForeground(orchid3);
		acceptButton.setFont(bfont);

		this.add(acceptButton);
	}

  }
  public button_panel(String a, String b, String c) 
  {
	GridLayout layout = new GridLayout(3,1,20,20);
	this.setLayout(layout);

	this.setBackground (Color.cyan);
 
	helpButton = new Button ("Help");
	helpButton.setFont(bfont);
	this.add(helpButton);
	aboutButton = new Button("About");
	aboutButton.setFont(bfont);
	this.add(aboutButton);
	quitButton = new Button ("Quit");
	quitButton.setFont(bfont);
	this.add(quitButton);
							  
		
  }
 

 
}
