Re: ispell broken in CVS, right?


Subject: Re: ispell broken in CVS, right?
From: Dom Lachowicz (cinamod@hotmail.com)
Date: Tue May 01 2001 - 20:03:03 CDT


Hi Paul,

>Any suggestions?
>
>Paul

As usual, I'm full of suggestions:

>I've finally got a fresh view of the tree, and as far as I can tell,
>there's
>no way to get ispell-based squiggles working on any platform without some
>sort of API change.

No, you're wrong, but that's a good thing here :-)

What we want is a mapping between language tags (en-US, de-DE) and
dictionaries (american.hash, german.hash, etc...). There's no point in
keeping around the language tags if we can't use them :) So in
ISpellChecker.cpp we want to create some sort of mapping table.

>Essentially down in ISpellChecker::requestDictionary() there's a hardcoded
>"american.hash" which, of course, can never be located. Even if we're not
>going to honor AP_PREF_KEY_SpellCheckWordList, we still need some way for
>that method to look for dictionaries relative to
>AP_PREF_KEY_SpellDirectory.

The hardcodedness will change, at least as far as "american.hash" goes.
Joaquin did that really quickly to just get things to compile after my
changes. Now, as for the preference, why not use the following dumbed-down
pseudo-code:

XAP_App * pApp = XAP_App::get_instance();
XAP_Prefs * pPrefs = pApp->getPrefs();
pPrefs->getValue (SpellDirectory, & result);
string_append (result, mapLangtoHash());
load_dictionary(result);

...

Looks good, no?

Dom

_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com



This archive was generated by hypermail 2b25 : Sat May 26 2001 - 03:50:59 CDT