Package java.awt

Examples of java.awt.TextArea$MouseEventFilter


            }
        });

        tabPane.setLayout(new BorderLayout(7, 7));

        final TextArea textArea = new TextArea("", 60, 110, TextArea.SCROLLBARS_BOTH);
        textArea.setForeground(Color.black);
        textArea.setEditable(false);
        // Font font = Isis.getConfiguration().getFont("isis.debug.font", new
        // Font("Monospaced", Font.PLAIN, 10));
        final Font font = new Font("Monospaced", Font.PLAIN, 11);
        textArea.setFont(font);
        tabPane.add("Center", textArea);
        field = textArea;

        final Panel buttons = new Panel();
        buttons.setLayout(new FlowLayout());
View Full Code Here


    mainFrame = new Frame();
    mainFrame.setLayout(null);
    mainFrame.setSize(600, 507);
    mainFrame.addWindowListener(this);

    txtArea = new TextArea();
    txtArea.setBounds(12, 36, 550, 348);
    txtArea.setEditable(false);
    mainFrame.add(txtArea);

    txtField = new TextField();
View Full Code Here

     * @return java.awt.TextArea
     */
    private TextArea getMessageTextArea() {
        if (iMessageTextArea == null) {
            try {
                iMessageTextArea = new TextArea();
                iMessageTextArea.setName("MessageTextArea");
                iMessageTextArea.setFont(new Font("monospaced", 0, 12));
                iMessageTextArea.setText("");
                iMessageTextArea.setEditable(false);
                iMessageTextArea.setEnabled(true);
View Full Code Here

      add(p, constr);
      secure_note = new Label("This cookie will only be sent over secure connections");
      discard_note = new Label("This cookie will be discarded at the end of the session");
      c_url_note = new Label("");
      comment_label = new Label("Comment:");
      comment_value = new TextArea("", 3, 45, TextArea.SCROLLBARS_VERTICAL_ONLY);
      comment_value.setEditable(false);

      add(new Panel(), constr);

      constr.gridwidth = 1;
View Full Code Here

 
  public void test(TestHarness harness)
  {
    this.harness = harness;
    a = new TextField(5);
    b = new TextArea(10, 10);
    add(a, BorderLayout.EAST);
    add(b, BorderLayout.WEST);
    setSize(200,200);
    show();
   
View Full Code Here

   */
  public void test(TestHarness harness)
  {
    Frame f = new Frame();
    List l = new List(10);
    TextArea t = new TextArea(10, 10);
    f.setSize(300, 300);
    t.setBounds(10, 10, 100, 100);
    l.setBounds(0, 0, 100, 100);
   
    t.setVisible(true);
    l.setVisible(false);
    f.add(l);
    f.add(t);
    f.show();
   
    Robot r = harness.createRobot();
    r.waitForIdle();
    r.delay(1000);
   
    Point po = l.getLocation();
    harness.check(t.isVisible(), true);
    harness.check(f.isVisible(), true);
    harness.check(l.isVisible(), false);
    harness.check(f.getComponentAt(po.x, po.y) == l);
  }
View Full Code Here

  }
 
  public void testConstructor1(TestHarness harness)
  {
    harness.checkPoint("()");
    TextArea ta = new TextArea();
    harness.check(ta.getText(), "");
    harness.check(ta.isEditable());
    harness.check(ta.getColumns(), 0);
    harness.check(ta.getScrollbarVisibility(), TextArea.SCROLLBARS_BOTH);
  }
View Full Code Here

  }
 
  public void testConstructor2(TestHarness harness)
  {
    harness.checkPoint("(int, int)");
    TextArea ta = new TextArea(3, 7);
    harness.check(ta.getText(), "");
    harness.check(ta.isEditable());
    harness.check(ta.getColumns(), 7);
    harness.check(ta.getRows(), 3);
    harness.check(ta.getScrollbarVisibility(), TextArea.SCROLLBARS_BOTH);
   
    // try negative rows
    ta = new TextArea(-1, 7);
    harness.check(ta.getText(), "");
    harness.check(ta.isEditable());
    harness.check(ta.getRows(), 0);
    harness.check(ta.getColumns(), 7);
    harness.check(ta.getScrollbarVisibility(), TextArea.SCROLLBARS_BOTH);

    // try negative columns
    ta = new TextArea(3, -7);
    harness.check(ta.getText(), "");
    harness.check(ta.isEditable());
    harness.check(ta.getRows(), 3);
    harness.check(ta.getColumns(), 0)
    harness.check(ta.getScrollbarVisibility(), TextArea.SCROLLBARS_BOTH);
  }
View Full Code Here

  }
 
  public void testConstructor3(TestHarness harness)
  {
    harness.checkPoint("(String)");
    TextArea ta = new TextArea("ABC");
    harness.check(ta.getText(), "ABC");
    harness.check(ta.isEditable());
    harness.check(ta.getRows(), 0);
    harness.check(ta.getColumns(), 0);
    harness.check(ta.getScrollbarVisibility(), TextArea.SCROLLBARS_BOTH);
   
    // try null
    ta = new TextArea(null);
    harness.check(ta.getText(), "");
    harness.check(ta.isEditable());
    harness.check(ta.getRows(), 0);
    harness.check(ta.getColumns(), 0);
    harness.check(ta.getScrollbarVisibility(), TextArea.SCROLLBARS_BOTH);
  }
View Full Code Here

  }
 
  public void testConstructor4(TestHarness harness)
  {
    harness.checkPoint("(String, int, int)");
    TextArea ta = new TextArea("ABC", 3, 7);
    harness.check(ta.getText(), "ABC");
    harness.check(ta.isEditable());
    harness.check(ta.getRows(), 3);
    harness.check(ta.getColumns(), 7);
    harness.check(ta.getScrollbarVisibility(), TextArea.SCROLLBARS_BOTH);
   
    // try null
    ta = new TextArea(null, 3, 7);
    harness.check(ta.getText(), "");
    harness.check(ta.isEditable());
    harness.check(ta.getRows(), 3);
    harness.check(ta.getColumns(), 7);
    harness.check(ta.getScrollbarVisibility(), TextArea.SCROLLBARS_BOTH);
   
    // try negative rows
    ta = new TextArea("ABC", -3, 7);
    harness.check(ta.getText(), "ABC");
    harness.check(ta.isEditable());
    harness.check(ta.getRows(), 0);
    harness.check(ta.getColumns(), 7);
    harness.check(ta.getScrollbarVisibility(), TextArea.SCROLLBARS_BOTH);

    // try negative columns
    ta = new TextArea("ABC", 3, -7);
    harness.check(ta.getText(), "ABC");
    harness.check(ta.isEditable());
    harness.check(ta.getRows(), 3);
    harness.check(ta.getColumns(), 0);
    harness.check(ta.getScrollbarVisibility(), TextArea.SCROLLBARS_BOTH);
  }
View Full Code Here

TOP

Related Classes of java.awt.TextArea$MouseEventFilter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.