Javascript: TXTextControl.InsertionMode Enumeration
Description
Determines how text is inserted at the current input position when text is typed or inserted.
Members
| Member | Description |
|---|---|
| Insert | Text is inserted at the current input position, and existing text is moved to the right. |
| Overwrite | Text at the current input position is overwritten by the newly inserted text. |
Examples
The following example uses TXTextControl.InsertionMode.Insert (text is inserted at the current input position, and existing text is moved to the right.) in a document-editing workflow.
function onTxError(error) {
console.error("TX Text Control error:", error.msg);
error.handled = true;
}
TXTextControl.setInsertionMode(
TXTextControl.InsertionMode.Insert,
function() {
console.log("set insertion mode completed.");
},
onTxError
);