Esempio n. 1
0
        /// <summary>
        /// Called when [intellisense show].
        /// </summary>
        /// <param name="sender">The sender.</param>
        /// <param name="e">The <see cref="TextCompositionEventArgs"/> instance containing the event data.</param>
        private void OnIntellisenseShow(object sender, TextCompositionEventArgs e)
        {
            var line = Document.GetLineByNumber(TextArea.Caret.Line);

            // show only if nothing valid was typed in current line yet
            if (!syntaxChecker.Validate(Document.GetText(line)))
            {
                intellisense.Show();
            }
            else
            {
                intellisense.Close();
            }
        }