Skip to content

NoteComposerPluginInstance.getSelectionUnderHeading method

NoteComposerPluginInstance › getSelectionUnderHeading

Unofficial

Get the text selection range under a heading at the given line.

Signature:

getSelectionUnderHeading(file: TFile, editor: Editor, line: number): HeadingInfo | null

Parameters:

Parameter Type Description
file TFile The source file.
editor Editor The active editor.
line number The line number of the heading.

Returns: HeadingInfo | nullThe heading info, or null if no heading found.