public class

FocusingTextField

extends TextField
java.lang.Object
   ↳ java.awt.Component
     ↳ java.awt.TextComponent
       ↳ java.awt.TextField
         ↳ sun.awt.FocusingTextField

Class Overview

FocusingTextField: a subclass of java.awt.TextField that handles moving the input focus from field to field, as when the user hits 'return.'

Summary

[Expand]
Inherited Constants
From class java.awt.Component
From interface java.awt.image.ImageObserver
[Expand]
Inherited Fields
From class java.awt.TextComponent
Public Constructors
FocusingTextField(int cols)
Create a FocusingTextField.
FocusingTextField(int cols, boolean willSelect)
Create a FocusingTextField.
Public Methods
boolean getWillSelect()
boolean gotFocus(Event e, Object arg)
This method is deprecated. As of JDK version 1.1, replaced by processFocusEvent(FocusEvent).
boolean lostFocus(Event e, Object arg)
This method is deprecated. As of JDK version 1.1, replaced by processFocusEvent(FocusEvent).
void nextFocus()
This method is deprecated. As of JDK version 1.1, replaced by transferFocus().
void setNextField(TextField next)
Call this to set the next field to receive the input focus.
void setWillSelect(boolean will)
[Expand]
Inherited Methods
From class java.awt.TextField
From class java.awt.TextComponent
From class java.awt.Component
From class java.lang.Object
From interface java.awt.MenuContainer
From interface java.awt.image.ImageObserver
From interface javax.accessibility.Accessible

Public Constructors

public FocusingTextField (int cols)

Create a FocusingTextField.

Parameters
cols number of columns of text.

public FocusingTextField (int cols, boolean willSelect)

Create a FocusingTextField.

Parameters
cols number of columns of text.
willSelect if true, will select all contents of field when focus is gained.

Public Methods

public boolean getWillSelect ()

public boolean gotFocus (Event e, Object arg)

This method is deprecated.
As of JDK version 1.1, replaced by processFocusEvent(FocusEvent).

We got the focus. If willSelect is true, select everything.

public boolean lostFocus (Event e, Object arg)

This method is deprecated.
As of JDK version 1.1, replaced by processFocusEvent(FocusEvent).

We lost the focus. If willSelect is true, deselect everything.

public void nextFocus ()

This method is deprecated.
As of JDK version 1.1, replaced by transferFocus().

Pass the focus to the next guy, if any.

public void setNextField (TextField next)

Call this to set the next field to receive the input focus.

Parameters
next the next TextField in order - can be null.

public void setWillSelect (boolean will)