Exemple #1
0
        public ScintillaBrace(Scintilla scintillaControl)
        {
            _scintillaControl = scintillaControl;

            _scintillaControl.Styles[Style.BraceLight].BackColor = Color.LightGray;
            _scintillaControl.Styles[Style.BraceLight].ForeColor = Color.BlueViolet;
            _scintillaControl.Styles[Style.BraceBad].ForeColor = Color.Red;

            _scintillaControl.UpdateUI += scintillaControl_UpdateUI;
            _parentForm = _scintillaControl.FindForm();
            _parentForm.KeyDown += ParentForm_KeyDown;
            _parentForm.KeyPreview = true;
        }
        public void ShowReplace()
        {
            if (!Window.Visible)
            {
                Window.Show(Scintilla.FindForm());
            }

            Window.tabAll.SelectedTab = Window.tabAll.TabPages["tpgReplace"];

            Range selRange = Scintilla.Selection.Range;

            if (selRange.IsMultiLine)
            {
                Window.chkSearchSelectionR.Checked = true;
            }
            else if (selRange.Length > 0)
            {
                Window.cboFindR.Text = selRange.Text;
            }

            Window.cboFindR.Select();
            Window.cboFindR.SelectAll();
        }
Exemple #3
0
        public void ShowFind()
        {
            if (!_window.Visible)
            {
                _window.Show(Scintilla.FindForm());
            }

            _window.tabAll.SelectedTab = _window.tabAll.TabPages["tpgFind"];

            Range selRange = Scintilla.Selection.Range;

            if (selRange.IsMultiLine)
            {
                _window.chkSearchSelectionF.Checked = true;
            }
            else if (selRange.Length > 0)
            {
                _window.cboFindF.Text = selRange.Text;
            }

            _window.cboFindF.Select();
            _window.cboFindF.SelectAll();
        }