Interface SelectionRangeProvider

interface SelectionRangeProvider {
    provideSelectionRanges(document, positions, token): ProviderResult<SelectionRange[]>;
}

Methods

  • Provide selection ranges for the given positions.

    Selection ranges should be computed individually and independent for each position. The editor will merge and deduplicate ranges but providers must return hierarchies of selection ranges so that a range is contained by its parent.

    Parameters

    Returns ProviderResult<SelectionRange[]>

    Selection ranges or a thenable that resolves to such. The lack of a result can be signaled by returning undefined or null.