public class nUIEntryElement extends nUIElementDisplay
Y_IDENTIFIER_PREV_BOTTOM
COLOR_BACKGROUND_NORMAL, COLOR_BLACK, COLOR_FOREGROUND_DARK, COLOR_FOREGROUND_LIGHT, COLOR_FOREGROUND_NORMAL, COLOR_TRANSPARENT, COLOR_WHITE, DIMENSIONS_IDENTIFIER_PARENT_DIMENSIONS
event_listener, event_listener_exclusive, first_child, last_child, next_sibling, nuiid, parent, prev_sibling, unlink_children_on_removal_from_parent
Constructor and Description |
---|
nUIEntryElement(int nuiid,
java.lang.String text)
Default data-entry constructor
|
Modifier and Type | Method and Description |
---|---|
boolean |
getEditable() |
int |
getFontSize()
Gets the current font size.
|
int |
getFontStyle()
Gets the current font style used for text on this button.
|
java.lang.String |
getFormat()
Gets the current format String.
|
java.lang.String |
getHintText()
Gets the hint text.
|
int |
getLines()
Gets the current number of lines shown to the user to type into.
|
java.lang.String |
getText()
Gets the currently entered text.
|
int |
getTextColor() |
void |
setEditable(boolean editable) |
void |
setEditing(boolean editing) |
void |
setFontSize(int font_size)
Sets the size of the font to use.
|
void |
setFontSizeAbsolute(int size_in_pixels,
boolean accessibility_adjusted)
Sets absolute font size in pixels.
|
void |
setFontSizeRelative(int rel_font_id,
int scale)
Sets font size relative to the one of the predefined sizes.
|
void |
setFontStyle(int font_style)
Sets the style of the font to use.
|
void |
setFormat(java.lang.String format)
Sets the allowable text format of this entry element.
|
void |
setHintText(java.lang.String hinttext)
Sets the hint text to display when no text is shown.
|
void |
setLines(int lines)
Sets the number of lines shown to the user to type into.
|
void |
setText(java.lang.String text)
Sets the text to display.
|
void |
setTextColor(int color) |
getY, insertAt
getBottom, getFocus, getFocusable, getGesturable, getHeight, getInnerHeight, getInnerWidth, getInnerX, getInnerY, getLeft, getMaxChildX, getMaxChildY, getRight, getScreenInnerX, getScreenInnerY, getScreenX, getScreenY, getTop, getTopLevelParentView, getTopLevelParentWindow, getTriggerable, getWidth, getX, insertAtInternal, remove, setBottom, setChildFocus, setFocus, setFocusable, setGesturable, setHeight, setInnerHeight, setInnerWidth, setInnerX, setInnerY, setLeft, setRight, setTop, setTriggerable, setWidth, setX, setY
add, addEventListener, childElementAt, childIndexOf, insertAfter, insertBefore, outputChildHierarchy, remove, removeEventListener, replace, replace
public nUIEntryElement(int nuiid, java.lang.String text)
nuiid
- Unique Native UI ID (or -1 if unidentified)text
- The default text to display to begin withpublic int getTextColor()
public void setTextColor(int color)
public void setFontStyle(int font_style)
font_style
- Any of nUIConstants.style_*
java.lang.IllegalArgumentException
- if font_style is not validpublic int getFontStyle()
nUIConstants.style_*
public void setFontSize(int font_size)
font_size
- One of the following NUIConstants: size_tiny, size_samll, size_medium, size_large, size_hugejava.lang.IllegalArgumentException
- if font_size is not validpublic int getFontSize()
public void setFontSizeAbsolute(int size_in_pixels, boolean accessibility_adjusted)
size_in_pixels
- any positive numberaccessibility_adjusted
- if true, some platforms can scale the actual font size depending on system properties.public void setFontSizeRelative(int rel_font_id, int scale)
rel_font_id
- one of the following NUIConstants: size_tiny, size_samll, size_medium, size_large, size_hugescale
- positive number in percentages.public void setLines(int lines)
lines
- Number of lines to displayjava.lang.IllegalArgumentException
- is lines is less than or equal to 0public int getLines()
public void setText(java.lang.String text)
text
- Text to displayjava.lang.NullPointerException
- if text is nullpublic java.lang.String getText()
public void setHintText(java.lang.String hinttext)
hinttext
- Hint text to displayjava.lang.NullPointerException
- if text is nullpublic java.lang.String getHintText()
public void setFormat(java.lang.String format)
public java.lang.String getFormat()
public void setEditing(boolean editing)
public void setEditable(boolean editable)
public boolean getEditable()