www.pudn.com > 2007419349385.rar > kh.java


import java.applet.*;
import java.awt.*;
import java.awt.event.*;

public class kh extends Applet implements ActionListener
{   
    Button b1=new Button("人员信息");
    Button b2=new Button("房产信息");
    Button b3=new Button("收费信息");
    Button b4=new Button("公共设施信息");
    Button b5=new Button("返回");
    Panel p1=new Panel( );
    Panel p2=new Panel( );
    Panel p3=new Panel( );
    
    public void init( )
    {
	setBackground( Color.pink);
	
	p1.setLayout(new FlowLayout(FlowLayout.CENTER,200,80));
	p1.add(b1);
	b1.setBackground(Color.green);
	b1.addActionListener(this);
	p1.add(b2);
	b2.setBackground(Color.green);
	b2.addActionListener(this);
	p1.setFont(new  Font("CHINESE_GB2312",Font.BOLD,60));
	add(p1);
	p2.setLayout(new FlowLayout(FlowLayout.LEFT,80,56));
	p2.add(b3);
	b3.setBackground(Color.green);
	b3.addActionListener(this);
	p2.add(b4);
	b4.setBackground(Color.green);
	b4.addActionListener(this);
	p2.setFont(new  Font("CHINESE_GB2312",Font.BOLD,60));
	add(p2);
	p3.setLayout(new FlowLayout(FlowLayout.CENTER,0,0));
	p3.add(b5);
	b5.setBackground(Color.yellow);
	b5.addActionListener(this);
	add(p3);
    }
    public void actionPerformed(ActionEvent e)
    {
    }
}