</COMMENT>
/**
 * HTMLTest.java - Cory J. Goldfuss - 05 Feb 2001
 * Program allows user to play with the HTML ability of a JLabel
 */

import java.awt.*;
import javax.swing.*;
import java.awt.event.*;


public class HTMLTest extends JApplet implements ActionListener
{
	public void init()
	{
		
		
		// This line prevents the "Swing: checked access to system event queue" message seen in some browsers.
		getRootPane().putClientProperty("defeatSystemEventQueueCheck", Boolean.TRUE);
		
		// This code is automatically generated by Visual Cafe when you add
		// components to the visual environment. It instantiates and initializes
		// the components. To modify the code, only use code syntax that matches
		// what Visual Cafe can generate, or Visual Cafe may be unable to back
		// parse your Java file into its visual environment.
		//{{INIT_CONTROLS
		getContentPane().setLayout(null);
		getContentPane().setBackground(java.awt.Color.pink);
		setSize(455,323);
		JenterBtn.setText("Enter");
		JenterBtn.setActionCommand("Enter");
		JenterBtn.setToolTipText("Enter HTML Code");
		JenterBtn.setMnemonic((int)'E');
		getContentPane().add(JenterBtn);
		JenterBtn.setBounds(24,288,84,29);
		JhtmLbl.setHorizontalTextPosition(javax.swing.SwingConstants.LEFT);
		JhtmLbl.setVerticalTextPosition(javax.swing.SwingConstants.TOP);
		JhtmLbl.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
		JhtmLbl.setVerticalAlignment(javax.swing.SwingConstants.TOP);
		JhtmLbl.setAutoscrolls(true);
		JhtmLbl.setOpaque(true);
		JhtmLbl.setToolTipText("HTML Shows Here.");
		getContentPane().add(JhtmLbl);
		JhtmLbl.setBackground(java.awt.Color.white);
		JhtmLbl.setBounds(228,12,215,298);
		Jinput.setLineWrap(true);
		Jinput.setWrapStyleWord(true);
		Jinput.setToolTipText("Enter HTML Coder Here.");
		Jinput.setCursor(java.awt.Cursor.getPredefinedCursor(java.awt.Cursor.TEXT_CURSOR));
		getContentPane().add(Jinput);
		Jinput.setBounds(12,12,208,216);
		JclearBtn.setText("Erase");
		JclearBtn.setToolTipText("Start Over.");
		JclearBtn.setMnemonic((int)'R');
		getContentPane().add(JclearBtn);
		JclearBtn.setBounds(120,288,84,24);
		JclearBtn.setVisible(false);
		JTextArea1.setRequestFocusEnabled(false);
		JTextArea1.setText("Do not enter the  or  tags, this is done automatically.");
		JTextArea1.setLineWrap(true);
		JTextArea1.setWrapStyleWord(true);
		JTextArea1.setEditable(false);
		JTextArea1.setCursor(java.awt.Cursor.getPredefinedCursor(java.awt.Cursor.WAIT_CURSOR));
		getContentPane().add(JTextArea1);
		JTextArea1.setFont(new Font("Dialog", Font.BOLD, 11));
		JTextArea1.setBounds(12,240,204,36);
		//}}
		
		JenterBtn.addActionListener( this );
		JclearBtn.addActionListener( this );
	}

	//{{DECLARE_CONTROLS
	javax.swing.JButton JenterBtn = new javax.swing.JButton();
	javax.swing.JLabel JhtmLbl = new javax.swing.JLabel();
	javax.swing.JTextArea Jinput = new javax.swing.JTextArea();
	javax.swing.JButton JclearBtn = new javax.swing.JButton();
	javax.swing.JTextArea JTextArea1 = new javax.swing.JTextArea();
	//}}
	
	
	public void actionPerformed( ActionEvent e){
	    if ( e.getSource() == JenterBtn){
	        String HTMLCode = new String (Jinput.getText().trim());
	        JhtmLbl.setText("" + HTMLCode + "");
	        showStatus("HTML Entered.");
	        JclearBtn.setVisible( true );
	    }
	    
	    if ( e.getSource() == JclearBtn){
	        JclearBtn.setVisible( false );
	        JhtmLbl.setText("");
	        Jinput.setText("");
	    }
	    
	    
	    
	}
}