Wintertree Software Inc.

Sentry Spelling Checker Engine for Windows

Home Site index Contact us Catalog Shopping Cart Products Support Search

You are here: Home > Products > Developer tools > Sentry Spelling Checker Engine > Windows > Technical details


Technical details

Click here for more information about Sentry Spell Checker Engine for Windows

The Sentry Spelling-Checker Engine's API provides direct, straightforward calling from C, C++, Visual Basic, VB.NET, C#, Delphi, MFC, and other DLL-enabled applications. Only simple data types (integers and character strings) are used in the API. All the constants, data types, and function prototypes you’ll need are contained within a single include file. The Sentry DLL is self-contained and is not dependent on any other DLLs.

Application Program Interface (API) Summary

CheckCtrlBackground
Monitors a rich-edit control (CRichEditCtrl, TRichEdit, RichTextBox, TX Text Control) for spelling errors as the user types. Misspelled words are marked (e.g., by changing the text to red), and corrected words are unmarked (e.g., by changing the text back to black). Right-clicking the mouse over a misspelled word pops up a menu containing suggested replacements. Selecting one of the suggestions in the menu replaces the misspelled word.

CheckCtrlDlg
Checks the spelling of text contained in a text box or rich-text box, identified by a window handle. If any misspelled words are detected, CheckCtrlDlg highlights the misspelled word in the text box and pops up a built-in dialogue box to interact with the user to dispose of the problem. This powerful function makes it possible to add a spellchecker to your application with just one statement!

CheckBlockDlg
Checks the spelling of text contained in a string or character array (a text block). If any misspelled words are detected, CheckBlockDlg pops up a built-in dialog box to interact with the user to dispose of the problem. CheckBlockDlg can optionally display the checked string so the user can see the misspelled word in context. CheckBlockDlg makes it possible to add a spell checker to any application with just one statement!

CheckString
Checks the spelling of words in a text string: a phrase, sentence, paragraph, or an entire document. CheckString is non-interactive, meaning it reports misspelled words back to your application without interacting with the user. CheckString returns to your application when it finds the next misspelled word in the text or when it reaches the end of the text. CheckString also reports incorrectly capitalized words and words requiring automatic or conditional correction.

CheckWord
Like CheckString, but spellchecks one word at a time. Your application would use CheckWord to check the spelling of a single word without interacting with the user.

Suggest
Locates suggested alternative spellings for a misspelled word. Also produces a score, expressed as a percentage, showing the degree of correlation for each alternative word found. The set of words is returned in order of decreasing score, so the first word is the best choice. Suggestions can be located using typographical (looks like) or phonetic (sounds like, Metaphone) matching, or both.

 ReplaceStringWord, DelStringWord
Replace one word in a text string with another (used to correct misspellings), or delete a word in a text string (used to delete doubled words).

AddToLex, DelFromLex
Adds or removes words to or from user dictionaries.

GetLexInfo, GetLex
Obtains information about a dictionary, or obtains a copy of its contents.

GetStatistics
Returns statistics about the last text block or control spell checked, including the number of words checked and the number of word replacements made.

EditLexDlg
Displays a dialog box which allows the user to manage a set of user dictionaries and to edit the contents of any user dictionary. Users can open, close, and create new user dictionary files.

OptionsDlg
Displays a dialog box which allows the user to set spelling-checker options.

CompressLexInit, CompressLexFile, CompressLexEnd
Creates a new compressed dictionary from words contained in one or more word list files.

Properties

The following properties can be set through the API, system registry, or INI file:

AutoCorrect
Determines if automatic replacements defined in a dictionary (e.g., CORRECT.TLX) should be made automatically; set to 0 if the changes should be treated as suggested replacements.

CaseSensitive
Determines if Sentry should treat words identified with different letter-case patterns as different words; set to 0 if words differing only in their case patterns should be considered identical.

DebugFile
Set to the name of a file used to record diagnostic events; delete or set to an empty value to disable diagnostic logging.

HelpFile
Name of the help file invoked when the user presses the Help button on a dialog.

IgnoreHTMLMarkups
Controls whether HTML markups appearing in the text should be ignored (skipped).

IgnoreAllCapsWords
Controls whether words consisting entirely of capital letters should be ignored (skipped); set to 0 if they should be spell checked.

IgnoreMixedCase
Controls whether words containing an unusual mixture of upper- and lower-case letters should be ignored; set to 0 if they should be spell checked.

IgnoreCappedWords
Controls whether words beginning with a capital letter should be ignored (skipped); set to 0 if they should be spell checked.

IgnoreDomainNames
Controls whether if words that appear to be Internet domain names, e-mail addresses, and URLs (e.g., wintertree-software.com) should be ignored; set to 0 if they should be spell checked.

IgnoreMixedDigits
Controls whether words containing a mixture of letters and digits should be ignored; set to 0 if they should be spell checked.

MainLexFiles
Comma-separated list of lexicon (dictionary) files forming the main lexicon. Each file name can contain a path relative to the MainLexPath directory or an absolute path name. Your application can change the dictionaries used by the Sentry engine (to change the language, for example) by setting this property.

MainLexPath
Path to the directory containing the main lexicon (dictionary) files.

PhoneticSuggestions
Controls whether suggestions should include words which sound like the misspelled word; set to 0 if phonetic suggestions should not be given.

ReportDoubledWords
Controls whether the same word appearing twice in a row should be reported to the user; set to 0 if the word should be ignored.

SplitHyphenatedWords
Controls whether Sentry should treat hyphens as word separators, and spell check each individual word (only if the original hyphenated word was not found); set to 0 if hyphenated words should be spell checked in the entirely only.

SuggestSplitWords
Controls whether suggestions can include two shorter words formed by splitting the misspelled word (e.g., suggest "the dog" for "thedog"); set to 0 if suggestions of this form should not be offered.

TypographicalSuggestions
Controls whether suggestions for misspelled words should include words which are typographically similar to the misspelled word; set to 0 if typographical suggestions should not be given.

UserLexFiles
Comma-separated list of user lexicon (dictionary) files. Each file can contain a path relative to the UserLexPath directory or an absolute path.

UserLexPath
Path to the directory containing user lexicon (dictionary) files.

Click here for more information about Sentry Spell Checker Engine for Windows


Home Site index Contact us Catalog Shopping Cart Products Support Search


Copyright © 2015 Wintertree Software Inc.