Example #1
0
        private void FindResultsScintilla_KeyUp(object sender, KeyEventArgs e)
        {
            int pos          = FindResultsScintilla.CurrentPosition;
            int selectedLine = FindResultsScintilla.LineFromPosition(pos);

            if (_findAllResults.Count > selectedLine)
            {
                ScintillaNET.FindReplaceDialog.CharacterRange CharRange = _findAllResults[selectedLine];
                Scintilla.SetSelection(CharRange.cpMin, CharRange.cpMax);
                Scintilla.ScrollCaret();
            }
        }
Example #2
0
        private void FindResultsScintilla_MouseClick(object sender, MouseEventArgs e)
        {
            int pos = FindResultsScintilla.CharPositionFromPointClose((e.Location).X, (e.Location).Y);

            if (pos == -1)
            {
                return;
            }

            int selectedLine = FindResultsScintilla.LineFromPosition(pos);

            ScintillaNET.FindReplaceDialog.CharacterRange CharRange = _findAllResults[selectedLine];
            Scintilla.SetSelection(CharRange.cpMin, CharRange.cpMax);
            Scintilla.ScrollCaret();
        }