Commit: Spelling Suggesion Speed-ups


Subject: Commit: Spelling Suggesion Speed-ups
From: Dom Lachowicz (cinamod@hotmail.com)
Date: Tue Apr 24 2001 - 17:39:56 CDT


In case you hadn't noticed (at least on pspell builds) coming up with
context suggestions for misspelled words is absolutely horrible. The problem
isn't as noticable for ispell for various reasons related to how ispell
works but it still exists, nonetheless.

What I did was implement some pretty good caching in one method called
FV_View::_lookupSuggestions(). Basically, we used to do this to generate the
right-click menu:

for (index = 1..9)
{
suggestion = FV_View->getSuggestion(index);
addSuggestionToMenu(index, suggestion);
}

Now, that isn't too bad. But when you consider that getSuggestion always
called down into pspell or ispell 9 or 10x for the same word, you're talking
about a lot of overhead. Well, this is fixed now.

Dom

CVS: ----------------------------------------------------------------------
CVS: Enter Log. Lines beginning with `CVS:' are removed automatically
CVS:
CVS: Committing in .
CVS:
CVS: Modified Files:
CVS: fv_View.cpp
CVS: ----------------------------------------------------------------------
_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com



This archive was generated by hypermail 2b25 : Tue Apr 24 2001 - 17:40:00 CDT