Interface: TextEditor
libs/common/types/TextEditor.TextEditor
Represents a read-only reference to a text editor. If you need to modify the editor, use IDE.getEditableTextEditor.
Hierarchy
TextEditor
Properties
document
• Readonly
document: TextDocument
The document associated with this text editor. The document will be the same for the entire lifetime of this text editor.
Defined in
libs/common/types/TextEditor.ts:25
id
• Readonly
id: string
Unique identifier for this text editor
Defined in
libs/common/types/TextEditor.ts:20
isActive
• Readonly
isActive: boolean
True if this text editor is active.
Defined in
libs/common/types/TextEditor.ts:46
options
• Readonly
options: TextEditorOptions
Text editor options.
Defined in
libs/common/types/TextEditor.ts:41
selections
• Readonly
selections: Selection
[]
The selections in this text editor.
Defined in
libs/common/types/TextEditor.ts:36
visibleRanges
• Readonly
visibleRanges: Range
[]
The current visible ranges in the editor (vertically). This accounts only for vertical scrolling, and not for horizontal scrolling.
Defined in
libs/common/types/TextEditor.ts:31
Methods
isEqual
▸ isEqual(other
): boolean
Check if this text editor is equal to other
.
Parameters
Name | Type | Description |
---|---|---|
other | TextEditor | A text editor. |
Returns
boolean
true
if the this text editor is equal to other
.
Defined in
libs/common/types/TextEditor.ts:54