Package com.ardor3d.extension.ui.text
Class TextSelection
java.lang.Object
com.ardor3d.extension.ui.text.TextSelection
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected int
protected Mesh
The mesh used to render this selection.protected int
protected TextSelection.SelectionState
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
protected Mesh
void
downKey()
Alter the selection as if the "shift" and "down" keys are pressed.void
draw
(Renderer renderer, ReadOnlyTransform xform) abstract int
int
int
int
getState()
abstract RenderedText.RenderedTextData
void
leftKey()
Alter the selection as if the "shift" and "left" keys are pressed.void
reset()
void
rightKey()
Alter the selection as if the "shift" and "right" keys are pressed.void
setEndIndex
(int endIndex) void
setStartIndex
(int startIndex) void
void
upKey()
Alter the selection as if the "shift" and "up" keys are pressed.
-
Field Details
-
_startIndex
protected int _startIndex -
_endIndex
protected int _endIndex -
_state
-
_standin
The mesh used to render this selection.
-
-
Constructor Details
-
TextSelection
public TextSelection()
-
-
Method Details
-
getCaretPosition
public abstract int getCaretPosition()- Returns:
- the current caret position within the component whose selection we are tracking.
-
getTextData
- Returns:
- the data object of the text associated with this selection.
-
getSelectionLength
public int getSelectionLength() -
reset
public void reset() -
getEndIndex
public int getEndIndex() -
setEndIndex
public void setEndIndex(int endIndex) -
getStartIndex
public int getStartIndex() -
setStartIndex
public void setStartIndex(int startIndex) -
getState
-
setState
-
upKey
public void upKey()Alter the selection as if the "shift" and "up" keys are pressed. -
downKey
public void downKey()Alter the selection as if the "shift" and "down" keys are pressed. -
leftKey
public void leftKey()Alter the selection as if the "shift" and "left" keys are pressed. -
rightKey
public void rightKey()Alter the selection as if the "shift" and "right" keys are pressed. -
checkStart
public void checkStart() -
draw
-
createSelectionMesh
-