Adding TX Spell .NET

1. Select Add Reference... from the Project main menu. In the opened Add Reference dialog box, open the Browse tab page and browse for the installation folder of TX Spell .NET for WPF. The default folder is:

C:\Program Files\Text Control GmbH\TX Spell 7.0 .NET for WPF\Assembly\

Select TXSpell.dll and TXSpell.WPF.dll from the Assembly folder and confirm with OK.

2. The TX Spell .NET namespace must be added to the Window XAML. Additionally, TX Spell .NET must be added as a resource to the Window. The complete XAML should look like this:

<Window x:Class="Simple.MainWindow"
        Title="MainWindow" Height="350" Width="525"

        <spell:TXSpellChecker x:Key="txSpellChecker1"></spell:TXSpellChecker>

            SpellChecker="txSpellChecker1" />

3. The SpellChecker property of TextControl must be set with the key name of the created TXSpellChecker instance. Add the property to the TextControl element in the XAML as shown in the code above.

4. Additionally, the IsSpellCheckingEnabled property of TextControl must be set to true.

5. To enable hyphenation, set the IsHyphenationEnabled property of TextControl to true.

6. Open the licenses.licx file, which is located in the Properties folder (C#) or the My Project folder (VB.NET).

Add the following entry:

TXTextControl.WPF.Proofing.TXSpellChecker, TXSpell.WPF

Build and start the application to see the first results. The spell-as-you-type functionality and the English dictionary is enabled by default. Misspelled words are underlined automatically and can be corrected by using the shipped right-click context menu. Using this menu, you can open the integrated dialog box as well. In addition, on reaching the end of a line, the last word is hyphenated by using the corresponding English hyphenation list.