Extension Dictionaries

From Apache OpenOffice Wiki
Revision as of 09:24, 26 February 2008 by Tl (Talk | contribs)

Jump to: navigation, search

Problem with current dictionary.lst file

In order to get rid of the problems involved with the dictionary.lst file at upgrade (see issue 72559) we have to forsake the use of it and provide the necessary information about dictionaries in the configuration.

Already provided configuration entries

Each implementation of spell checker, hyphenator or thesaurus needs to have an entry in the configuration (i.e. the file Linguistic.xcu) stating it's implementation name (for purposes of identification) and the file formats name of the dictionaries it can handle. More than one file format can be listed if supported.

The dictionary file format names for the current OOo linguistic are

  • DICT_SPELL
  • DICT_HYPH and
  • DICT_THES


Thus the respective entries do look like this:

  • Spell checker entry
<node oor:name="ServiceManager">
    <node oor:name="SpellCheckers">
        <node oor:name="org.openoffice.lingu.MySpellSpellChecker" oor:op="fuse">
            <prop oor:name="SupportedDictionaryFormats" oor:type="oor:string-list">
                <value>DICT_SPELL</value>
            </prop>
        </node>

        ... entries for other spell checkers ...
    </node>
</node>
  • Hyphenator entry
<node oor:name="ServiceManager">
    <node oor:name="Hyphenators">
        <node oor:name="org.openoffice.lingu.LibHnjHyphenator" oor:op="fuse">
            <prop oor:name="SupportedDictionaryFormats" oor:type="oor:string-list">
                <value>DICT_HYPH</value>
            </prop>
        </node>

        ... entries for other hyphenators ...
    </node>
</node>
  • Thesaurus entry
<node oor:name="ServiceManager">
        <node oor:name="org.openoffice.lingu.new.Thesaurus" oor:op="fuse">
            <prop oor:name="SupportedDictionaryFormats" oor:type="oor:string-list">
                <value>DICT_THES</value>
            </prop>
        </node>

        ... entries for other thesauri ...
</node>


The only link between one of the above services and the dictionaries to be used by them is the name of the dictionary format. When invoked the services are required to check in the configuration which dictionaries they can make use of and thus establishing their set of dictionaries to use. This is done by looking at the format names of the configured dictionaries.

Required entries

The entries that are still missing and need to be provided are those for the dictionaries. Each entry consists of

  • a unique name (the node name in the configuration)
  • a list of file locations (the ones actually needed by the service implementation)
  • a single format name and
  • a list of locales listing the languages the dictionary may be used for
Personal tools