private void _btnModal_Click(object sender, RoutedEventArgs e)
        {
            // select control to spell-check
            object editor = _plainTextBox;

            // select type of modal dialog to use
            Window dialog = null;

            switch (selectedSpellDialogIndex)
            {
            // C1SpellChecker built-in dialog
            case 0:
                dialog = new C1SpellDialog();
                break;

            // Customized C1SpellChecker built-in dialog
            case 1:
                dialog       = new C1SpellDialog();
                dialog.Title = "Customized Caption!";
                break;

            // Standard dialog
            case 2:
                dialog = new StandardSpellDialog();
                break;

            // Word-style dialog
            case 3:
                dialog = new WordSpellDialog();
                break;
            }

            // spell-check the control
            _c1SpellChecker.CheckControlAsync(editor, false, (ISpellDialog)dialog);
        }
예제 #2
0
 private void Button_Click(object sender, RoutedEventArgs e)
 {
     _c1SpellChecker.CheckControlAsync(_plainTextBox);
 }