System\Windows\Documents\TextStore.cs (59)
342selection[0].start = this.TextSelection.Start.CharOffset;
343selection[0].end = this.TextSelection.End.CharOffset;
344selection[0].style.ase = (this.TextSelection.MovingPosition.CompareTo(this.TextSelection.Start) == 0) ? UnsafeNativeMethods.TsActiveSelEnd.TS_AE_START : UnsafeNativeMethods.TsActiveSelEnd.TS_AE_END;
378this.TextSelection.SetCaretToPosition(start, LogicalDirection.Backward, /*allowStopAtLineEnd:*/true, /*allowStopNearSpace:*/true);
382this.TextSelection.Select(end, start);
386this.TextSelection.Select(start, end);
396this.TextSelection.OnInterimSelectionChanged(_interimSelection);
685ITextRange range = new TextRange(this.TextSelection.AnchorPosition, this.TextSelection.MovingPosition);
725this.TextSelection.ApplyTypingHeuristics(false /* overType */);
753if (start.CompareTo(this.TextSelection.Start) != 0 ||
754end.CompareTo(this.TextSelection.End) != 0)
756this.TextSelection.Select(start, end);
767_previousCompositionStartOffset = this.TextSelection.Start.Offset;
768_previousCompositionEndOffset = this.TextSelection.End.Offset;
1439TextSelection.OnInterimSelectionChanged(_interimSelection);
1491if (TextEditor.AllowOvertype && TextEditor._OvertypeMode && TextSelection.IsEmpty)
1496navigator = TextSelection.End.CreatePointer();
1514TextSelection.ExtendToNextInsertionPosition(LogicalDirection.Forward);
1520string filteredText = FilterCompositionString(result, TextSelection.Start.GetOffsetToPosition(TextSelection.End)); // does NOT filter MaxLength.
1526this.TextEditor.SetText(TextSelection, filteredText, InputLanguageManager.Current.CurrentInputLanguage);
1527TextSelection.Select(TextSelection.End, TextSelection.End);
1778if ((compositionStart.CompareTo(TextSelection.Start) <= 0) &&
1779(compositionStart.CompareTo(TextSelection.End) <= 0) &&
1780(compositionEnd.CompareTo(TextSelection.Start) >= 0) &&
1781(compositionEnd.CompareTo(TextSelection.End) >= 0))
1792fReconvertable = GetFnReconv(TextSelection.Start, TextSelection.End, out funcReconv, out range);
1817fReconvertable = GetFnReconv(TextSelection.Start, TextSelection.End, out funcReconv, out range);
1924pointer = this.TextSelection.Start.CreatePointer(direction);
2010this.TextSelection.BeginChange();
2018this.TextSelection.Select(range.Start, range.End);
2022this.TextSelection.SetCaretToPosition(range.End, LogicalDirection.Backward, /*allowStopAtLineEnd:*/true, /*allowStopNearSpace:*/true);
2040this.TextSelection.EndChange();
3152if (compositionStart != null && compositionStart.CompareTo(this.TextSelection.Start) > 0)
3158start = this.TextSelection.Start;
3161CompositionParentUndoUnit unit = new CompositionParentUndoUnit(this.TextSelection, start, start, _nextUndoUnitIsFirstCompositionUnit);
3548int imeSelectionAnchorOffset = this.TextSelection.AnchorPosition.Offset;
3549int imeSelectionMovingOffset = this.TextSelection.MovingPosition.Offset;
3603TextParentUndoUnit textParentUndoUnit = new TextParentUndoUnit(this.TextSelection, this.TextSelection.Start, this.TextSelection.Start);
3788appSelectionAnchorOffset = this.TextSelection.AnchorPosition.Offset;
3789appSelectionMovingOffset = this.TextSelection.MovingPosition.Offset;
3815appSelectionAnchorOffset = this.TextSelection.AnchorPosition.Offset;
3816appSelectionMovingOffset = this.TextSelection.MovingPosition.Offset;
3882this.TextSelection.BeginChangeNoUndo();
3968this.TextSelection.Select(anchor, moving);
3989this.TextSelection.Select(anchor, moving);
3999this.TextSelection.EndChange(false /* disableScroll */, true /* skipEvents */);
4020this.TextSelection.BeginChangeNoUndo();
4027this.TextSelection.EndChange(false /* disableScroll */, true /* skipEvents */);
4049this.TextSelection.BeginChangeNoUndo();
4056this.TextSelection.EndChange(false /* disableScroll */, true /* skipEvents */);