private void SelectionManagerSelectionChanged(object sender, EventArgs e) { string text = TextEditor.ActiveTextAreaControl.TextArea.SelectionManager.SelectedText; TextEditor.Document.MarkerStrategy.RemoveAll(m => true); IList<TextMarker> selectionMarkers = GetTextMarkersMatchingWord(text); foreach (var selectionMarker in selectionMarkers) { TextEditor.Document.MarkerStrategy.AddMarker(selectionMarker); } _diffHighlightService.AddPatchHighlighting(TextEditor.Document); TextEditor.ActiveTextAreaControl.TextArea.Invalidate(); }
public void AddPatchHighlighting() { _diffHighlightService.AddPatchHighlighting(TextEditor.Document); }