import javax.swing.*;
import java.awt.*;


/**
 * A window a text area.
 */
public class TextJFrame extends JFrame {


  /** The window's text area. */
  JTextArea textArea;

  /**
   * Create a window with a 10x20-character text area.
   */
  public TextJFrame() {
    
    // 10 chars wide, 20 lines high.
    this.textArea= new JTextArea("Text area.", 10, 20); 

    // Add the text area to this window.
    Container c = this.getContentPane();
    c.add(this.textArea);
    
    this.pack();
    this.setVisible(true);
  }
}
