|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjewl.Window
jewl.Control
jewl.TextControl
The abstract base class for controls which contain a text string. Any such control provides methods for getting and setting the text that the control contains,as well as controlling the text alignment within the control (left justified, right justified or centred).
| Field Summary | |
static int |
CENTER
Used for centred text. |
static int |
CENTRE
Used for centred text, using British spelling. |
static int |
LEFT
Used for left-aligned text. |
static int |
RIGHT
Used for right-aligned text. |
| Method Summary | |
int |
getAlignment()
Get the alignment of this control's text within its allocated area. |
java.lang.String |
getText()
Get the text displayed by the control. |
void |
setAlignment(int align)
Set the alignment of this control's text within its allocated area. |
void |
setKey(char key)
Set a mnemonic key. |
void |
setText(java.lang.String text)
Set the text displayed by the control. |
| Methods inherited from class jewl.Control |
disable, enable, enable, getToolTip, isEnabled, setToolTip |
| Methods inherited from class jewl.Window |
addEventListener, commandAvailable, getCommand, getFont, getHeight, getID, getLeft, getScreenHeight, getScreenWidth, getSource, getTop, getWidth, hide, init, isVisible, nextCommand, parent, root, setFont, setID, setLocation, setSize, show, show |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final int LEFT
public static final int CENTRE
public static final int CENTER
public static final int RIGHT
| Method Detail |
public void setAlignment(int align)
align - the desired alignment, specified using one of the values LEFT,
RIGHT, CENTRE or CENTER.public int getAlignment()
public void setText(java.lang.String text)
text - the text for the control to display.public java.lang.String getText()
public void setKey(char key)
key - a letter or digit which will activate the button when pressed
together with the Alt key. Anything other than a letter or digit
will be ignored.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||