Wintertree Software Inc.

Sentry Spelling Checker Engine - Support

Home Site index Contact us Catalog Shopping Cart Products Support Search

You are here: Home > Support > Sentry Spelling Checker Engine > Misspelled words not detected after "&" or "<"


Misspelled words not detected after "&" or "<"

Product: Sentry Spelling Checker Engine Windows SDK, Sentry Spelling Checker Engine Source SDK

Problem: If the text being checked contains a "&" or "<" character, the Sentry engine seems to stop checking. It won't find any misspelled words after the "&" or "<" character.

Discussion: This behavior is by design. It occurs when the SSCE_IGNORE_HTML_MARKUPS_OPT option (or IgnoreHTMLMarkups property in the Sentry Windows DLL) is set to 1. When this property is set to True, the Sentry engine expects the text to contain correctly formatted HTML. In correctly formatted HTML, the "&" and "<" are special characters (known as meta-characters). The "&" character is used to signal the beginning of an HTML character entity, such as "&copy;" for a copyright symbol. The "<" is used to signal the beginning of an HTML markup, such as "<b>" for boldface. When the Sentry engine sees these characters, it expects either a character entity or markup to follow. More accurately, it begins skipping text until it encounters the terminator of the character entity or markup. The terminator of a character entity is ";", and the terminator of a markup is ">". Thus, the appearance of "&" in the text acts like a switch that causes text to be skipped until a ";" appears (similarly for "<" and ">"). This behavior is documented in the Sentry programmer's guide in the description of the SSCE_IGNORE_HTML_MARKUPS_OPT option and IgnoreHTMLMarkups property.

Beginning in version 5.15, the Sentry engine will skip text when a "&" or "<" character is encountered until the corresponding terminator or the end of the line appears, whichever comes first.

Solution: Either set SSCE_IGNORE_HTML_MARKUPS_OPT to 0, or ensure the text contains correctly formatted HTML. A literal "&" character should be entered as "&amp;", and a literal "<" character should be entered as "&lt;".


Home Site index Contact us Catalog Shopping Cart Products Support Search


Copyright © 2015 Wintertree Software Inc.