Skip to Content
ClassesFDocument

Class: FDocument

Properties

PropertyModifierType

id

readonly

string

Methods

appendText()

appendText(text): Promise<boolean>;

Adds the specified text to the end of this text region.

Parameters

ParameterTypeDescription
textstringThe 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

IDocumentData


redo()

redo(): Promise<boolean>;

Returns

Promise<boolean>


setSelection()

setSelection(startOffset, endOffset): void;

Sets the selection to a specified text range in the document.

Parameters

ParameterTypeDescription
startOffsetnumberThe starting offset of the selection in the document.
endOffsetnumberThe ending offset of the selection in the document.

Returns

void

Example

document.setSelection(10, 20);

undo()

undo(): Promise<boolean>;

Returns

Promise<boolean>