예제 #1
0
        public void MoveSelectionLeft()
        {
            if (IsEmpty)
            {
                return;
            }

            Begin = End =
                PrintedTokens
                .Select(t => t.Token.Index)
                .Where(F.IsLessThan(End))
                .DefaultIfEmpty(0)
                .Last();

            onChanged();
        }
예제 #2
0
        public void MoveSelectionRight()
        {
            if (IsEmpty)
            {
                return;
            }

            Begin = End =
                PrintedTokens
                .Select(t => t.Token.Index + t.Token.Length)
                .Where(F.IsGreaterThan(End))
                .DefaultIfEmpty(Text.Length)
                .First();

            onChanged();
        }