CorrectionHandler Class
- Namespace
TXTextControl.Proofing
- Package
TXTextControl.from the private NuGet feed or Text Control Offline PackagesTXSpell. WPF. SDK
- Assembly
TXSpell.dll
- Install
dotnet add package TXTextControl..NET 8 and later. For .NET Framework, referenceTXSpell. WPF. SDK TXSpell.from the setup.dll
- Also in
TXTextControl.asTXSpell. Core. SDK TXSpell.dll
- Implements
- INotify
Property Changed
Description
The CorrectionHandler class provides methods and properties which are necessary to construct the correction handling part of a spelling correction user interface.
Syntax
public sealed class SpellingCorrectionUIProvider.CorrectionHandler : INotifyPropertyChangedPublic NotInheritable Class SpellingCorrectionUIProvider.CorrectionHandler
Implements INotifyPropertyChangedExamples
The following example includes the is add to dictionary enabled value from a Correction Handler object in application diagnostics. The created object is then available to the surrounding document workflow.
Console.WriteLine($"Is Add To Dictionary Enabled: {correctionHandler.IsAddToDictionaryEnabled}");
Console.WriteLine("Correction Handler is ready for use.");Console.WriteLine($"Is Add To Dictionary Enabled: {correctionHandler.IsAddToDictionaryEnabled}")
Console.WriteLine("Correction Handler is ready for use.")Members
Properties
| Property | Description |
|---|---|
| IsAddToDictionaryEnabled | Gets a value whether the AddToDictionary method is enabled or not. |
| IsChangeAllEnabled | Gets a value whether the ChangeAll method is enabled or not. |
| IsChangeEnabled | Gets a value whether the Change method is enabled or not. |
| IsDeleteEnabled | Gets a value whether the Delete method is enabled or not. |
| IsIgnoreAllEnabled | Gets a value whether the IgnoreAll method is enabled or not. |
| IsIgnoreEnabled | Gets a value whether the Ignore method is enabled or not. |
| IsOptionsEnabled | Gets a value whether the current SpellingCorrectionUIProvider's mode is set to OptionsSettings or not. |
| IsUndoEditEnabled | Gets a value whether the current SpellingCorrectionUIProvider's mode is set to WordToCorrectEditing or not. |
Methods
| Method | Description |
|---|---|
| AddToDictionary | Adds the text of the current word to correct to all user dictionaries of the current dictionary collection where the IsEditable property is set to true and the language property corresponds to the TXTextControl.MisspelledWord.Culture or incorrect word's language property. Furthermore the word is removed from all corresponding collections (TXTextControl.MisspelledWordCollection/ IncorrectWordCollection). |
| Change | Replaces the current word to correct with a specified word. |
| ChangeAll | Replaces all words to correct, that have the same text like the current uncorrected word. |
| CheckCorrectedWord | Returns a value whether the specified word was found in one of the current selected suggestion dictionaries or not. |
| Delete | Deletes the current word to correct. |
| Ignore | Ignores the current misspelled. |
| IgnoreAll | Ignores all words to correct, that have the same text like the current uncorrected word. |
Events
| Event | Description |
|---|---|
| PropertyChanged | Not described in the reference. public event PropertyChangedEventHandler PropertyChanged; |