|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcharva.awt.Component
charvax.swing.JComponent
charvax.swing.text.JTextComponent
charvax.swing.JTextField
Support for public void setBounds( Rectangle bounds ) public void setBounds( int top_, int left_, int bottom_, int right_) public void setBounds(Point topleft_, Dimension size_)
| Field Summary | |
protected java.util.Vector |
_actionListeners
A list of ActionListeners registered for this component. |
protected boolean |
_bold
|
protected int |
_columns
|
protected int |
_offset
Index (from the start of the string) of the character displayed in the left corner of the field. |
protected java.lang.String |
_padding
A blank-filled string the same length as the JTextField. |
| Fields inherited from class charvax.swing.text.JTextComponent |
_caretPosition, _document, _editable |
| Fields inherited from class charvax.swing.JComponent |
_border |
| Fields inherited from class charva.awt.Component |
_alignmentX, _alignmentY, _background, _cursesColor, _enabled, _focusListeners, _foreground, _keyListeners, _origin, _parent, _visible, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Constructor Summary | |
JTextField()
Construct a text field. |
|
JTextField(int length_)
Use this constructor when you want to leave the text field empty but set its length. |
|
JTextField(java.lang.String text_)
Use this constructor when you want to initialize the value. |
|
JTextField(java.lang.String text_,
int length_)
Use this constructor when you want to set both the initial value and the length. |
|
| Method Summary | |
void |
addActionListener(ActionListener al_)
Register an ActionListener object for this component. |
void |
debug(int level_)
|
void |
draw()
Called by this JTextField's parent container. |
java.lang.String |
getActionCommand()
Get the action command |
int |
getColumns()
Return the number of columns in the text field. |
int |
getHeight()
|
Dimension |
getSize()
Return the size of the text field. |
int |
getWidth()
|
boolean |
isEditable()
Returns the boolean flag indicating whether this TextComponent is editable or not. |
Dimension |
minimumSize()
Called by the LayoutManager. |
void |
postActionEvent(ActionEvent ae_)
Invoke all the ActionListener callbacks that may have been registered for this component. |
protected void |
processEvent(AWTEvent evt_)
Process events. |
void |
processKeyEvent(KeyEvent ke_)
Process KeyEvents that have been generated by this JTextField. |
void |
processMouseEvent(MouseEvent e_)
Process a MouseEvent that was generated by clicking the mouse somewhere inside this JTextField. |
void |
requestFocus()
This method should be invoked by all subclasses of Component which override this method; because this method generates the FOCUS_GAINED event when the component gains the keyboard focus. |
void |
setActionCommand(java.lang.String cmd_)
Set the action command |
void |
setBounds(int top_,
int left_,
int bottom_,
int right_)
|
void |
setBounds(Point topleft_,
Dimension size_)
|
void |
setBounds(Rectangle bounds)
|
void |
setColumns(int columns_)
Sets the number of columns in this Textfield, and then invalidates the layout. |
void |
setEditable(boolean editable_)
Sets whether this textfield can be edited. |
void |
setFont(Font font_)
|
void |
setText(java.lang.String text_)
Set the text that is presented by this JTextField. |
java.lang.String |
toString()
Returns a String representation of this component. |
| Methods inherited from class charvax.swing.text.JTextComponent |
getCaretPosition, getDocument, getText, setCaretPosition, setDocument |
| Methods inherited from class charvax.swing.JComponent |
getBorder, getInsets, setBorder |
| Methods inherited from class charva.awt.Component |
addFocusListener, addKeyListener, contains, contains, getAlignmentX, getAlignmentY, getAncestorWindow, getBackground, getBounds, getCursesColor, getForeground, getLocation, getLocationOnScreen, getName, getParent, hasFocus, hide, invalidate, isDisplayed, isEnabled, isFocusTraversable, isTotallyObscured, isValid, isVisible, processFocusEvent, repaint, requestSync, setBackground, setEnabled, setForeground, setLocation, setLocation, setName, setParent, setVisible, show, validate, validateCursesColor |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
protected boolean _bold
protected int _columns
protected int _offset
protected java.lang.String _padding
protected java.util.Vector _actionListeners
| Constructor Detail |
public JTextField()
public JTextField(java.lang.String text_)
public JTextField(int length_)
public JTextField(java.lang.String text_,
int length_)
| Method Detail |
public void setColumns(int columns_)
public void setBounds(Rectangle bounds)
setBounds in class Component
public void setBounds(int top_,
int left_,
int bottom_,
int right_)
setBounds in class Component
public void setBounds(Point topleft_,
Dimension size_)
setBounds in class Componentpublic int getColumns()
public void setFont(Font font_)
public void setActionCommand(java.lang.String cmd_)
public java.lang.String getActionCommand()
public Dimension getSize()
getSize in class Componentpublic int getWidth()
getWidth in class Componentpublic int getHeight()
getHeight in class Componentpublic Dimension minimumSize()
minimumSize in class Componentpublic void setEditable(boolean editable_)
setEditable in class JTextComponentpublic boolean isEditable()
JTextComponent
isEditable in class JTextComponentpublic void draw()
draw in class JComponentpublic void processKeyEvent(KeyEvent ke_)
processKeyEvent in class Componentpublic void processMouseEvent(MouseEvent e_)
processMouseEvent in class Componentpublic void setText(java.lang.String text_)
setText in class JTextComponentprotected void processEvent(AWTEvent evt_)
processEvent in class Componentpublic void postActionEvent(ActionEvent ae_)
public void addActionListener(ActionListener al_)
public void requestFocus()
Component
requestFocus in class Componentpublic java.lang.String toString()
public void debug(int level_)
debug in class Component
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||