Class: FDocument
Properties
Property | Modifier | Type |
---|---|---|
|
|
Methods
appendText()
appendText(text): Promise<boolean>
Adds the specified text to the end of this text region.
Parameters
Parameter | Type | Description |
---|---|---|
text | string | The text to be added to the end of this text region. |
Returns
Promise
<boolean
>
getId()
getId(): string
Returns
string
getName()
getName(): string
Returns
string
getSnapshot()
getSnapshot(): IDocumentData
Returns
redo()
redo(): Promise<boolean>
Returns
Promise
<boolean
>
setSelection()
setSelection(startOffset, endOffset): void
Sets the selection to a specified text range in the document.
Parameters
Parameter | Type | Description |
---|---|---|
startOffset | number | The starting offset of the selection in the document. |
endOffset | number | The ending offset of the selection in the document. |
Returns
void
Example
document.setSelection(10, 20);
undo()
undo(): Promise<boolean>
Returns
Promise
<boolean
>