VintaSoft Imaging .NET SDK 15.1: Документация для .NET разработчика
Vintasoft.Imaging.Spelling.UI Namespace / RichTextBoxSpellCheckManager Class
Члены типа Объект Синтаксис Example Иерархия Требования Смотрите также
В этом разделе
Класс RichTextBoxSpellCheckManager
В этом разделе
Предоставляет менеджер для проверки орфографии в System.Windows.Forms.RichTextBox.
Объектная модель
SpellCheckManager RichTextBoxSpellCheckManager
Синтаксис
'Declaration

Public Class RichTextBoxSpellCheckManager

public class RichTextBoxSpellCheckManager

Пример

Вот C#/VB.NET код, который демонстрирует, как создать RichTextBoxSpellCheckManager для указанного System.Windows.Forms.RichTextBox.


''' <summary>
''' Creates the spell check manager for specified <see cref="System.Windows.Forms.RichTextBox"/>.
''' </summary>
''' <param name="textBox">The rich text box.</param>
''' <param name="engines">The spell check engines.</param>
''' <returns>
''' The spell check manager for rich text box.
''' </returns>
Public Shared Function CreateManager(textBox As System.Windows.Forms.RichTextBox, engines As System.Collections.Generic.List(Of Vintasoft.Imaging.Spelling.ISpellCheckEngine)) As Vintasoft.Imaging.Spelling.UI.RichTextBoxSpellCheckManager
    ' create the spell check manager
    Dim spellCheckManager As New Vintasoft.Imaging.Spelling.SpellCheckManager()
    ' specify the spell check engines, which the spell check manager must use for spell checking
    spellCheckManager.Engines = engines

    ' create the spell check manager for a rich text box
    Dim richTextBoxSpellCheckManager As New Vintasoft.Imaging.Spelling.UI.RichTextBoxSpellCheckManager()
    ' specify the rich text box in which text must be spell checked
    richTextBoxSpellCheckManager.TextBox = textBox
    ' specify the spell check manager that should be used for spell checking of text in the rich text box
    richTextBoxSpellCheckManager.SpellCheckManager = spellCheckManager

    Return richTextBoxSpellCheckManager
End Function


/// <summary>
/// Creates the spell check manager for specified <see cref="System.Windows.Forms.RichTextBox"/>.
/// </summary>
/// <param name="textBox">The rich text box.</param>
/// <param name="engines">The spell check engines.</param>
/// <returns>
/// The spell check manager for rich text box.
/// </returns>
public static Vintasoft.Imaging.Spelling.UI.RichTextBoxSpellCheckManager CreateManager(
    System.Windows.Forms.RichTextBox textBox,
    System.Collections.Generic.List<Vintasoft.Imaging.Spelling.ISpellCheckEngine> engines)
{
    // create the spell check manager
    Vintasoft.Imaging.Spelling.SpellCheckManager spellCheckManager =
        new Vintasoft.Imaging.Spelling.SpellCheckManager();
    // specify the spell check engines, which the spell check manager must use for spell checking
    spellCheckManager.Engines = engines;

    // create the spell check manager for a rich text box
    Vintasoft.Imaging.Spelling.UI.RichTextBoxSpellCheckManager richTextBoxSpellCheckManager =
        new Vintasoft.Imaging.Spelling.UI.RichTextBoxSpellCheckManager();
    // specify the rich text box in which text must be spell checked
    richTextBoxSpellCheckManager.TextBox = textBox;
    // specify the spell check manager that should be used for spell checking of text in the rich text box
    richTextBoxSpellCheckManager.SpellCheckManager = spellCheckManager;

    return richTextBoxSpellCheckManager;
}

Иерархия наследования

System.Object
   Vintasoft.Imaging.Spelling.UI.RichTextBoxSpellCheckManager

Требования

Целевые платформы: .NET 10; .NET 9; .NET 8; .NET 7; .NET 6; .NET Framework 4.8, 4.7, 4.6, 4.5, 4.0, 3.5

Смотрите также