System\Windows\Documents\TextStore.cs (59)
331selection[0].start = this.TextSelection.Start.CharOffset;
332selection[0].end = this.TextSelection.End.CharOffset;
333selection[0].style.ase = (this.TextSelection.MovingPosition.CompareTo(this.TextSelection.Start) == 0) ? UnsafeNativeMethods.TsActiveSelEnd.TS_AE_START : UnsafeNativeMethods.TsActiveSelEnd.TS_AE_END;
367this.TextSelection.SetCaretToPosition(start, LogicalDirection.Backward, /*allowStopAtLineEnd:*/true, /*allowStopNearSpace:*/true);
371this.TextSelection.Select(end, start);
375this.TextSelection.Select(start, end);
385this.TextSelection.OnInterimSelectionChanged(_interimSelection);
674ITextRange range = new TextRange(this.TextSelection.AnchorPosition, this.TextSelection.MovingPosition);
714this.TextSelection.ApplyTypingHeuristics(false /* overType */);
742if (start.CompareTo(this.TextSelection.Start) != 0 ||
743end.CompareTo(this.TextSelection.End) != 0)
745this.TextSelection.Select(start, end);
756_previousCompositionStartOffset = this.TextSelection.Start.Offset;
757_previousCompositionEndOffset = this.TextSelection.End.Offset;
1425TextSelection.OnInterimSelectionChanged(_interimSelection);
1477if (TextEditor.AllowOvertype && TextEditor._OvertypeMode && TextSelection.IsEmpty)
1482navigator = TextSelection.End.CreatePointer();
1500TextSelection.ExtendToNextInsertionPosition(LogicalDirection.Forward);
1506string filteredText = FilterCompositionString(result, TextSelection.Start.GetOffsetToPosition(TextSelection.End)); // does NOT filter MaxLength.
1512this.TextEditor.SetText(TextSelection, filteredText, InputLanguageManager.Current.CurrentInputLanguage);
1513TextSelection.Select(TextSelection.End, TextSelection.End);
1761if ((compositionStart.CompareTo(TextSelection.Start) <= 0) &&
1762(compositionStart.CompareTo(TextSelection.End) <= 0) &&
1763(compositionEnd.CompareTo(TextSelection.Start) >= 0) &&
1764(compositionEnd.CompareTo(TextSelection.End) >= 0))
1775fReconvertable = GetFnReconv(TextSelection.Start, TextSelection.End, out funcReconv, out range);
1800fReconvertable = GetFnReconv(TextSelection.Start, TextSelection.End, out funcReconv, out range);
1907pointer = this.TextSelection.Start.CreatePointer(direction);
1993this.TextSelection.BeginChange();
2001this.TextSelection.Select(range.Start, range.End);
2005this.TextSelection.SetCaretToPosition(range.End, LogicalDirection.Backward, /*allowStopAtLineEnd:*/true, /*allowStopNearSpace:*/true);
2023this.TextSelection.EndChange();
3137if (compositionStart != null && compositionStart.CompareTo(this.TextSelection.Start) > 0)
3143start = this.TextSelection.Start;
3146CompositionParentUndoUnit unit = new CompositionParentUndoUnit(this.TextSelection, start, start, _nextUndoUnitIsFirstCompositionUnit);
3530int imeSelectionAnchorOffset = this.TextSelection.AnchorPosition.Offset;
3531int imeSelectionMovingOffset = this.TextSelection.MovingPosition.Offset;
3585TextParentUndoUnit textParentUndoUnit = new TextParentUndoUnit(this.TextSelection, this.TextSelection.Start, this.TextSelection.Start);
3770appSelectionAnchorOffset = this.TextSelection.AnchorPosition.Offset;
3771appSelectionMovingOffset = this.TextSelection.MovingPosition.Offset;
3797appSelectionAnchorOffset = this.TextSelection.AnchorPosition.Offset;
3798appSelectionMovingOffset = this.TextSelection.MovingPosition.Offset;
3864this.TextSelection.BeginChangeNoUndo();
3950this.TextSelection.Select(anchor, moving);
3971this.TextSelection.Select(anchor, moving);
3981this.TextSelection.EndChange(false /* disableScroll */, true /* skipEvents */);
4002this.TextSelection.BeginChangeNoUndo();
4009this.TextSelection.EndChange(false /* disableScroll */, true /* skipEvents */);
4031this.TextSelection.BeginChangeNoUndo();
4038this.TextSelection.EndChange(false /* disableScroll */, true /* skipEvents */);