コード例 #1
0
ファイル: TerminalPane.cs プロジェクト: VirusFree/VFTerminal
 private void EnterFreeSelectionMode()
 {
     TerminalDocument document = _tag.Document;
     _selectionKeyProcessor = new SelectionKeyProcessor(this, document, document.CurrentLine, document.CaretColumn);
     _caretTimer.Interval = Win32.GetCaretBlinkTime()/2;
     GEnv.Frame.SetSelectionStatus(SelectionStatus.Free);
 }
コード例 #2
0
ファイル: TerminalPane.cs プロジェクト: VirusFree/VFTerminal
 private void ExitFreeSelectionMode()
 {
     _selectionKeyProcessor = null;
     GEnv.Frame.SetSelectionStatus(SelectionStatus.None);
     GEnv.TextSelection.Clear();
     _caretTimer.Interval = Win32.GetCaretBlinkTime();
 }
コード例 #3
0
ファイル: TerminalPane.cs プロジェクト: VirusFree/VFTerminal
        public void ToggleFreeSelectionMode()
        {
            if(_tag==null) return;
            if(InAutoSelectionMode) ExitAutoSelectionMode();

            if(_selectionKeyProcessor==null) {
                EnterFreeSelectionMode();
                TerminalDocument document = _tag.Document;
                _selectionKeyProcessor = new SelectionKeyProcessor(this, document, document.CurrentLine, document.CaretColumn);
                _caretTimer.Interval = Win32.GetCaretBlinkTime()/2;
                //GEnv.Frame.StatusBar.IndicateSelectionMode();
            }
            else {
                ExitFreeSelectionMode();
                _selectionKeyProcessor = null;
                GEnv.Frame.SetSelectionStatus(0);
                GEnv.TextSelection.Clear();
                _caretTimer.Interval = Win32.GetCaretBlinkTime();
            }

            if(_inIMEComposition) {
                ClearIMEComposition();
            }
        }