Package com.vaadin.client.ui
Interface AbstractTextFieldWidget
-
- All Known Implementing Classes:
VPasswordField,VTextArea,VTextField
public interface AbstractTextFieldWidgetImplemented by all widgets used by a connector extendingAbstractTextFieldConnector.- Since:
- 8.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description intgetCursorPos()Gets the current cursor position inside the field.StringgetValue()Gets the current value of the field.voidselectAll()Selects all text in the field.voidsetReadOnly(boolean readOnly)Sets the read-only mode of the field.voidsetSelectionRange(int start, int length)Sets the selection range for the field.
-
-
-
Method Detail
-
setSelectionRange
void setSelectionRange(int start, int length)Sets the selection range for the field.- Parameters:
start- the start of the selectionlength- the length of the selection
-
getValue
String getValue()
Gets the current value of the field.- Returns:
- the current text in the field
-
selectAll
void selectAll()
Selects all text in the field.
-
setReadOnly
void setReadOnly(boolean readOnly)
Sets the read-only mode of the field.- Parameters:
readOnly-trueto set the field to read-only,falseotherwise
-
getCursorPos
int getCursorPos()
Gets the current cursor position inside the field.- Returns:
- the current cursor position
-
-