Share via


IMultiSelectionBroker.TryEnsureVisible Method

Definition

Attempts to make the given Selection visible in the view.

public:
 bool TryEnsureVisible(Microsoft::VisualStudio::Text::Selection selection, Microsoft::VisualStudio::Text::Editor::EnsureSpanVisibleOptions options);
public bool TryEnsureVisible (Microsoft.VisualStudio.Text.Selection selection, Microsoft.VisualStudio.Text.Editor.EnsureSpanVisibleOptions options);
abstract member TryEnsureVisible : Microsoft.VisualStudio.Text.Selection * Microsoft.VisualStudio.Text.Editor.EnsureSpanVisibleOptions -> bool
Public Function TryEnsureVisible (selection As Selection, options As EnsureSpanVisibleOptions) As Boolean

Parameters

selection
Selection

The selection to ensure visiblity on.

options
EnsureSpanVisibleOptions

How the selection span should be made visible.

Returns

true if the selection was in AllSelections and is now in view. false otherwise.

Remarks

This will first ensure that the selection span is visible, erring on the side of showing the ActivePoint. Then if the InsertionPoint is different than the ActivePoint, the InsertionPoint will be ensured visible.

Applies to