←Select platform

SpellCheckEngine Property

Gets or sets the current spell checker.
public OcrSpellCheckEngine SpellCheckEngine { get; set; } 
- (void)setSpellCheckEngine:(LTOcrSpellCheckEngine)spellCheckEngine error:(NSError **)error; 
public String getSpellLanguage() 
public void setSpellLanguage(String value) 
property OcrSpellCheckEngine SpellCheckEngine { 
   OcrSpellCheckEngine get(); 
   void set (    OcrSpellCheckEngine ); 
SpellCheckEngine # get and set (IOcrSpellCheckManager) 

Property Value

An OcrSpellCheckEngine enumeration member that specifies the current spell checker. The default value is OcrSpellCheckEngine.Native.


Set the value of SpellCheckEngine to OcrSpellCheckEngine.None to globally disable any spell checking and correction during the recognition process.

Not all OCR engine types support all available spell check engines. Call GetSupportedSpellCheckEngines to get a list of all supported spell check engines by the particular IOcrEngine and IsSpellCheckEngineSupported to determine whether the specified spell checker is supported.

For more information on spell check engines support, refer to OcrSpellCheckEngine.

using Leadtools; 
using Leadtools.Codecs; 
using Leadtools.Forms.Common; 
using Leadtools.Ocr; 
using Leadtools.Drawing; 
public void OcrSpellCheckManagerExample() 
   // Create an instance of the engine 
   using (IOcrEngine ocrEngine = OcrEngineManager.CreateEngine(OcrEngineType.LEAD)) 
      // Start the engine using default parameters 
      ocrEngine.Startup(null, null, null, LEAD_VARS.OcrLEADRuntimeDir); 
      IOcrSpellCheckManager spellCheckManager = ocrEngine.SpellCheckManager; 
      // Get the spell language supported (languages with a dictionary) 
      string[] spellLanguages = spellCheckManager.GetSupportedSpellLanguages(); 
      foreach (string spellLanguage in spellLanguages) 
      // Check if English is supported 
      string language = "en"; 
      if (spellCheckManager.IsSpellLanguageSupported(language)) 
         // Yes, set it 
         spellCheckManager.SpellLanguage = language; 
         Console.WriteLine("Current spell language: {0}", spellCheckManager.SpellLanguage); 
      // Enable the spell checking system 
      spellCheckManager.SpellCheckEngine = OcrSpellCheckEngine.Native; 
      // Now perform other OCR functions here 
      // Shutdown the engine 
      // Note: calling Dispose will also automatically shutdown the engine if it has been started 
static class LEAD_VARS 
   public const string OcrLEADRuntimeDir = @"C:\LEADTOOLS22\Bin\Common\OcrLEADRuntime"; 

Target Platforms

Help Version 22.0.2023.3.31
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.

Leadtools.Ocr Assembly

Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.