Constructor
new UITextInput(posopt, sizeopt, textopt)
Create a UITextInput object
Parameters:
| Name | Type | Attributes | Description |
|---|---|---|---|
pos | Vector2 | <optional> | |
size | Vector2 | <optional> | |
text | string | <optional> |
- Source
Extends
- UIObject
Members
maxLength
Properties| Type | Description |
|---|---|
| number | Max length of input (0 = no limit) |
- Source
Methods
click(playSoundopt)
Start editing the text, called when it is clicked
Parameters:
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
playSound | boolean | <optional> | true |
- Source
onKeyDown(e)
Key down event handler if this object is being edited
Parameters:
| Name | Type | Description |
|---|---|---|
e | KeyboardEvent |
- Source
stopEditing()
Stop editing the text
- Source