Parameters
Operational settings
These settings relate to how RapidSpell operates, rather than how the spell checker processes text, call any of the following lines to set the parameter
- rapidSpell.ayt_helperURL = "/path/rswihelper.aspx";
specifies the URL where rswihelper.aspx resides, by default this is automatically determined.
- rapidSpell.ayt_aytEnabled = true;
whether to do as-you-type checking.
- rapidSpell.ayt_staticMode = false;
whether to do static, button operated overlays with underlines.
- rapidSpell.ayt_recheckDelay = 500;
how many milliseconds to wait after the user stops typing to do the spell check.
- rapidSpell.ayt_showAddMenuItem = true;
whether to show the add menu item.
- rapidSpell.ayt_showIgnoreAllMenuItem = true;
whether to show the ignore all menu item.
- rapidSpell.dialog_popupURL = "/path/popup.aspx";
specifies the URL where popup.aspx resides, by default this is automatically determined.
- rapidSpell.dialog_modal = false;
whether the popup will be modal.
- rapidSpell.dialog_width = 370;
popup width.
- rapidSpell.dialog_height = 430;
popup height.
- rapidSpell.dialog_left = 100;
X coordinate of the popup.
- rapidSpell.dialog_top = 100;
Y coordinate of the popup.
Spell checker settings
These settings affect user experience, such as how the spell checker processes text, dictionaries and appearance etc.
Setting parameter values for a specific text box on the page
Call rapidSpell.setParameterValue(textBox, parameterName, value);
where 'textBox' is the text box element object (as returned by document.getElementById(textBoxId)). This will set the parameter for spell checking on that text box only, all other text boxes will use the default parameter values.
Setting default parameter values for all text boxes on a page
In Javascript, call rapidSpell.setParameterValue('default', parameterName, value);
Parameters
- UserDictionaryFile
see example
- SuggestionsMethod
PHONETIC_SUGGESTIONS or HASHING_SUGGESTIONS (default)
- SeparateHyphenWords
whether to treat hyphenated (-) words as separate words, default is false.
- IncludeUserDictionaryInSuggestions
whether the user dictionary should be used in finding suggestions for misspelt words, default is false.
- IgnoreXML
whether to ignore XML/HTML tags, false by default.
- IgnoreCapitalizedWords
whether to ignore words with capital letters, false by default.
- GuiLanguage
the UI language "ENGLISH", "FRENCH", "SPANISH", "GERMAN", "ITALIAN", "PORTUGUESE", "DUTCH", or "POLISH".
- LanguageParser
parser for current dictionary "ENGLISH", "FRENCH", "SPANISH", "GERMAN", "ITALIAN", "PORTUGUESE", "DUTCH", or "POLISH".
- AllowAnyCase
Whether to allow words spelt with incorrect case, eg. "africa", instead of "Africa", this is more relaxed than AllowMixedCase, default is false.
- IgnoreWordsWithDigits
whether to ignore words with numbers in them (eg. A10 or 7-11), true by default.
- ShowFinishedMessage
whether to show the popup dialog at the end of the spell check.
- ShowNoErrorsMessage
whether to show the popup dialog stating there were no spelling errors.
- AllowMixedCase
whether to allow words spelt with mixed case, eg. "MIxEd", default is false.
- WarnDuplicates
whether to treat duplicate words as errors (eg. "this is is an error"), true by default.
- DictFile
main dictionary (.dict) file path on the server (optional).
- ConsiderationRange
the size factor for words to consider for suggestions, lower values are faster but consider less words for suggestions. Default is 80. If w <= 1 this method won't do anyting.
- LookIntoHyphenatedText
whether to 'look into' text with hyphens (-), if the word has hyphens in it and LookIntoHyphenatedText is set true (default), the parts of the text around the hyphens will be checked individually.
- CheckCompoundWords
whether to check for compound words, setting this to true is essential for languages such as German which allow for compound words.
- EnableUndo
whether to provide 'undo' functionality to the user
when checking very large texts this may cause browser memory issues.
- LeaveWindowOpenForUndo
whether to leave the popup open after the last word so that the user can undo the last operation.
- IgnoreURLsAndEmailAddresses
whether to ignore URLs and email addresses, true by default.
- IgnoreIncorrectSentenceCapitalization
whether to ignore words starting sentences in lower case, false by default.
- IgnoreInEnglishLowerCaseI
whether to ignore lower case 'i' characters in text. Set to false (default) to flag as errors.
- SuggestSplitWords
whether to look for connected words in suggestions, true by default.
- FindCapitalizedSuggestions
whether to look for capitalized suggestions (when the error isn't capitalized), note this will slow FindSuggestions down by about 7 times.
Setting parameter values for a specific text box on the page
Call rapidSpell.setParameterValue(textBox, parameterName, value);
where 'textBox' is the text box element object (as returned by document.getElementById(textBoxId)). This will set the parameter for spell checking on that text box only, all other text boxes will use the default parameter values.