Beginning from Firefox-3.0b1 (also Thunderbird-3.0a1 and Seamonkey-2.0a1) it is possible to install an external spell-checker from an extension (bug 364035).
Implementing support of an spell-checker consists of the following steps:
- Implement a class derived from mozISpellCheckingEngine which implements required spell-checker functionality or accesses some external spell-checker. Spell-checker provided by extension can support one or several spell-checking dictionaries. It's method GetDictionaryList() should provide the list of supported dictionaries.
Provide both extension registration and unregistration callbacks. Extension registration callback must install category entry with name equal with contract id of class which implements the spell-checker functionality into category "spell-check-engine" using nsICategoryManager. Unregistration callback must remove this category entry. Developer may choose an arbitrary value for this category entry. For example one use of it can be to save a path of shared library of the extension provided as parameter for the registration callback for later use for locating other components of extension relatively to this shared library.
Spellchecker dictionary provided by an extension is used also if the same dictionary (for example en_EN) is provided by the application (Firefox, Thunderbird or Seamonkey) builtin spell-checker. That allows the extension to override the dictionary provided by builtin spellchecker. If the same dictionary is provided by more than one extension than one of them (the first found) is being used.