# Options Dialog

> The four tabs of the TX Spell .NET options dialog in Windows Forms and their properties: IgnoreWord, dictionaries, hyphenation, OptionsDialog, your own dialog.

- **Product:** TX Spell .NET for Windows Forms
- **Section:** Documentation
- **Kind:** Topic
- **Path:** TX Spell .NET for Windows Forms > User Interface > Options Dialog
- **3276 words**
- **Web URL:** https://docs.textcontrol.com/tx-spell-dotnet-winforms/user-interface/options-dialog/
- **LLMs URL:** https://docs.textcontrol.com/tx-spell-dotnet-winforms/user-interface/options-dialog/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-spell-dotnet-winforms/user-interface/options-dialog/llms-full.txt

---

Which words should the spell checker skip, which dictionaries should it use, and how should words be hyphenated? The **Options** dialog of TX Spell .NET lets the user of your application answer these questions without any code of yours. Read on for the tabs of the dialog and the properties behind each setting, how to open the dialog with some tabs only, and how to hide dictionaries from it or replace it with a dialog of your own.

### Open the Dialog

The user reaches the dialog in two ways, and your code in a third:

- **Options...** in the [spell check dialog](https://docs.textcontrol.com/tx-spell-dotnet-winforms/user-interface/spell-check-dialog/llms-full.txt) of TX Spell .NET.
- **Options...** in the context menu of a misspelled word, when the spell checker is connected to a `TextControl`. [Context Menus](https://docs.textcontrol.com/tx-spell-dotnet-winforms/user-interface/context-menus/llms-full.txt) shows the menu.
- The [OptionsDialog](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/txspellchecker/optionsdialog-method/llms-full.txt) method of the [TXSpellChecker](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/txspellchecker/llms-full.txt), called from a menu item or a button of your application:

```csharp
private void menuItemSpellingOptions_Click(object sender, EventArgs e)
{
    txSpellChecker1.OptionsDialog();
}
```

The dialog has the title **Options** and up to four tabs: **Spell Checking Options**, **Spell Checking Dictionaries**, **Hyphenation** and **Thesaurus**. It closes with **OK**.

### The Spell Checking Options Tab

The first tab decides which words the spell checker leaves alone:

![The Options dialog with the tabs Spell Checking Options and Spell Checking Dictionaries, opened from the Spelling dialog. All six check boxes of the first tab are checked, Ignore words in UPPERCASE is set to All and Ignore uppercase and lowercase to Only when word begin is upper.](https://docs.textcontrol.com/assets/img/tx-spell-dotnet-winforms/options-dialog-spelling.fc16f99f.webp)

Its settings are those of two properties of the `TXSpellChecker`, [IgnoreWord](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/txspellchecker/ignoreword-property/llms-full.txt) and [IgnoreCase](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/txspellchecker/ignorecase-property/llms-full.txt). Each setting has a related value in [TXSpell.IgnoreWordSettings](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/txspell-ignorewordsettings/enumeration/llms-full.txt) or [TXSpell.IgnoreCaseSettings](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/txspell-ignorecasesettings/enumeration/llms-full.txt):

| Setting | Related value |
|---|---|
| **Ignore words in UPPERCASE**, with **All** or **Only correct words** | `IgnoreWordSettings.InUpperCase` |
| **Ignore words that contain numbers** | `IgnoreWordSettings.WithNumbers` |
| **Ignore Internet addresses** | `IgnoreWordSettings.IsURL` |
| **Ignore E-Mail addresses** | `IgnoreWordSettings.IsEmail` |
| **Flag repeated words** | `IgnoreWordSettings.Duplicated` |
| **Ignore uppercase and lowercase**, with **All**, **Only at word begin** or **Only when word begin is upper** | `IgnoreCaseSettings` |

By default, words in uppercase, words with numbers, Internet addresses and e-mail addresses are ignored. [Ignore Settings](https://docs.textcontrol.com/tx-spell-dotnet-winforms/spell-checking/ignore-settings/llms-full.txt) explains each value and how to set it in code.

### The Spell Checking Dictionaries Tab

The second tab lists the dictionaries of the spell checker, one row each:

![The Options dialog over TX Text Control Words with all four tabs. The Spell Checking Dictionaries tab shows the dictionary en_US.dic, enabled for spell checking and for suggestions, with the language English (United States), and a User Dictionaries button below the list.](https://docs.textcontrol.com/assets/img/tx-spell-dotnet-winforms/options-dialog-dictionaries.40842cf9.webp)

| Column | Property of the [Dictionary](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/dictionary/llms-full.txt) |
|---|---|
| **Dictionary** | Its name, or its [DisplayName](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/dictionary/displayname-property/llms-full.txt) when you set one |
| **Spell Checking** | [IsSpellCheckingEnabled](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/dictionary/isspellcheckingenabled-property/llms-full.txt): the dictionary is used to check words |
| **Suggestions** | [IsGetSuggestionsEnabled](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/dictionary/isgetsuggestionsenabled-property/llms-full.txt): the dictionary is used to create suggestions |
| **Language** | The language of the dictionary |

A new dictionary is enabled for both. The user switches a dictionary off for checking or for suggestions with the check box in its cell. The list shows the dictionaries of the [Dictionaries](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/txspellchecker/dictionaries-property/llms-full.txt) property; [Loading and Managing Dictionaries](https://docs.textcontrol.com/tx-spell-dotnet-winforms/dictionaries/managing/llms-full.txt) shows how to add them.

**User Dictionaries...** opens a second dialog with the user dictionaries, the word lists the user adds words to:

![The User Dictionaries dialog in front of the Options dialog, with the user dictionary medical-custom marked as editable and the buttons Edit word list, Edit, New, Add, Remove and OK.](https://docs.textcontrol.com/assets/img/tx-spell-dotnet-winforms/user-dictionaries-dialog.c22e6e88.webp)

The user edits the words of a user dictionary, creates a new one, adds an existing file or removes one. The **Editable** column shows the [IsEditable](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/userdictionary/iseditable-property/llms-full.txt) property of each [UserDictionary](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/userdictionary/llms-full.txt): only an editable user dictionary takes the words of **Add To Dictionary**. [User Dictionaries](https://docs.textcontrol.com/tx-spell-dotnet-winforms/dictionaries/user/llms-full.txt) describes them.

### The Hyphenation and Thesaurus Tabs

The **Hyphenation** tab sets how words are hyphenated in the language chosen in its **Language** list. Each setting is a property of the [HyphenationList](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/hyphenationlist/llms-full.txt) of that language:

| Setting | Property |
|---|---|
| **Hyphenate words in UPPERCASE** | [HyphenateCapitalizedWords](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/hyphenationlist/hyphenatecapitalizedwords-property/llms-full.txt) |
| **Minimum number of characters at word begin** | [MinCharsAtWordBegin](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/hyphenationlist/mincharsatwordbegin-property/llms-full.txt) |
| **Minimum number of characters at word end** | [MinCharsAtWordEnd](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/hyphenationlist/mincharsatwordend-property/llms-full.txt) |
| **Use only compound hyphenation points** | [UseOnlyCompoundHyphenationPoints](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/hyphenationlist/useonlycompoundhyphenationpoints-property/llms-full.txt) |
| **Minimum of syllables before compound hyphenation points** | [MinSyllablesBeforeCompoundHyphenationPoint](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/hyphenationlist/minsyllablesbeforecompoundhyphenationpoint-property/llms-full.txt) |
| **Minimum of syllables after compound hyphenation points** | [MinSyllablesAfterCompoundHyphenationPoint](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/hyphenationlist/minsyllablesaftercompoundhyphenationpoint-property/llms-full.txt) |

[Change How Words Are Divided](https://docs.textcontrol.com/tx-spell-dotnet-winforms/hyphenation/lists/#change-how-words-are-divided) gives the default and the effect of each property.

The picture shows the tab of version 4.0, the version that introduced hyphenation. Its labels differ slightly from the current ones, but the settings are the same:

![The Hyphenation tab of the Options dialog in version 4.0 with the language English (United States), the check box Hyphenate words in UPPERCASE, the minimum numbers of characters at word end and begin set to 2, and the Compound words settings.](https://docs.textcontrol.com/assets/img/tx-spell-dotnet-winforms/options-hyphenation-tab.264e2266.webp)

The **Thesaurus** tab lists the synonym lists of the [SynonymLists](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/txspellchecker/synonymlists-property/llms-full.txt) property, with the columns **Thesaurus File**, **Create Synonyms** and **Language**. **Create Synonyms** is the [IsCreateSynonymsEnabled](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/synonymlist/iscreatesynonymsenabled-property/llms-full.txt) property of each [SynonymList](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/synonymlist/llms-full.txt). [Hyphenation Lists](https://docs.textcontrol.com/tx-spell-dotnet-winforms/hyphenation/lists/llms-full.txt) and [Synonym Lists](https://docs.textcontrol.com/tx-spell-dotnet-winforms/synonyms/lists/llms-full.txt) describe both kinds of lists.

### Show Only Some Tabs

An overload of `OptionsDialog` takes the tabs to show, as an array of their indices: 0 for **Spell Checking Options**, 1 for **Spell Checking Dictionaries**, 2 for **Hyphenation** and 3 for **Thesaurus**. An application without hyphenation and synonyms shows the first two:

```csharp
txSpellChecker1.OptionsDialog(new int[] { 0, 1 });
```

The array must contain at least one index; an empty array throws an `ArgumentException`. The first picture on this page shows the dialog with these two tabs, as it opens from the spell check dialog.

### Choose Where the Dialog Opens

The dialog opens in the center of the screen unless you pass a [ShowDialogSettings](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/showdialogsettings/llms-full.txt) object. This code centers it on the form that calls it:

```csharp
using TXTextControl.Proofing;

ShowDialogSettings settings = new ShowDialogSettings();
settings.Owner = this;
settings.StartPosition = TXSpell.DialogStartPosition.CenterOwner;

txSpellChecker1.OptionsDialog(settings, new int[] { 0, 1 });
```

The code works as follows:

- [Owner](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/showdialogsettings/owner-property/llms-full.txt) is the window that owns the dialog, here the form.
- [StartPosition](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/showdialogsettings/startposition-property/llms-full.txt) is a value of [TXSpell.DialogStartPosition](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/txspell-dialogstartposition/enumeration/llms-full.txt). `Manual` opens the dialog at the screen coordinates in [Location](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/showdialogsettings/location-property/llms-full.txt).
- Two more overloads take the settings alone, for all tabs, or the tabs alone, as above.

### Hide or Rename a Dictionary

Some dictionaries are part of your application and not the user's to switch off, such as a list of product names. Set [ShowInOptionsDialog](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/dictionary/showinoptionsdialog-property/llms-full.txt) to `false` before you add such a dictionary, and it is not listed in the dialog. A dictionary with a technical file name gets a readable name with `DisplayName`:

```csharp
// A dictionary the user doesn't see in the Options dialog
OpenOfficeDictionary products = new OpenOfficeDictionary("Dictionaries\\products.dic");
products.ShowInOptionsDialog = false;
txSpellChecker1.Dictionaries.Add(products);

// A readable name for the English dictionary
txSpellChecker1.Dictionaries.GetItem("en_US.dic").DisplayName = "English (US)";
```

The display name is used in the options dialog and in the **Suggestions Dictionary** list of the spell check dialog. *products.dic* stands for a dictionary file of your own in the *Dictionaries* folder of the application.

### Replace the Dialog With Your Own

The [OptionsDialogOpening](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/txspellchecker/optionsdialogopening-event/llms-full.txt) event fires before the dialog opens from `OptionsDialog` or from **Options...** in the spell check dialog. Set [Cancel](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/optionsdialogopeningeventargs/cancel-property/llms-full.txt) of its [OptionsDialogOpeningEventArgs](https://docs.textcontrol.com/tx-spell-dotnet-winforms/reference/txtextcontrol-proofing/optionsdialogopeningeventargs/llms-full.txt) to `true`, and show a form of your own instead:

```csharp
txSpellChecker1.OptionsDialogOpening += (sender, e) =>
{
    // Don't show the built-in dialog
    e.Cancel = true;

    using (SpellingSettingsForm settingsForm = new SpellingSettingsForm(txSpellChecker1))
    {
        settingsForm.ShowDialog(this);
    }
};
```

`SpellingSettingsForm` stands for a form of your application. It sets the properties that the tabs above set, such as `IgnoreWord`, `IgnoreCase` and the properties of the dictionaries. To take the options away from the user entirely, remove the **Options...** button from the spell check dialog, as [Customizing the Spell Check Dialog](https://docs.textcontrol.com/tx-spell-dotnet-winforms/user-interface/customizing-dialog/llms-full.txt) shows.

### Next Steps

- [Ignore Settings](https://docs.textcontrol.com/tx-spell-dotnet-winforms/spell-checking/ignore-settings/llms-full.txt): the settings of the first tab, in code.
- [Loading and Managing Dictionaries](https://docs.textcontrol.com/tx-spell-dotnet-winforms/dictionaries/managing/llms-full.txt): the dictionaries the second tab lists.
- [Spell Check Dialog](https://docs.textcontrol.com/tx-spell-dotnet-winforms/user-interface/spell-check-dialog/llms-full.txt): the dialog with the **Options...** button.
- [Context Menus](https://docs.textcontrol.com/tx-spell-dotnet-winforms/user-interface/context-menus/llms-full.txt): the menu with the **Options...** item.
- [Localization and Resource Kit](https://docs.textcontrol.com/tx-spell-dotnet-winforms/user-interface/localization/llms-full.txt): the dialog in the language of the user.

---

## Nearby

- **Previous:** [Customizing the Spell Check Dialog](https://docs.textcontrol.com/tx-spell-dotnet-winforms/user-interface/customizing-dialog/llms-full.txt)
- **Next:** [Context Menus](https://docs.textcontrol.com/tx-spell-dotnet-winforms/user-interface/context-menus/llms-full.txt)
