Stephan Witt wrote:
> The complete code fragment using forward() looks like that:
> ====================
> void GuiSpellchecker::forward()
> {
>         dispatch(FuncRequest(LFUN_ESCAPE));
>         dispatch(FuncRequest(LFUN_CHAR_FORWARD));
> }
>         
> void GuiSpellchecker::on_ignoreAllPB_clicked()
> {
>         /// replace all occurrences of word
>         if (d->word_.lang() && !d->word_.word().empty())
>                 theSpellChecker()->accept(d->word_);
>         forward();
>         check();
> }
> 
> void GuiSpellchecker::on_addPB_clicked()
> {
>         /// insert word in personal dictionary
>         theSpellChecker()->insert(d->word_);
>         forward();
>         check();
> }
> 
> void GuiSpellchecker::on_ignorePB_clicked()
> {
>         forward();
>         check();
> }
> ====================
> 
> The "replace" operation itself I didn't touch.

OK. Then there should be no problem.

> AFAIKS, the behavior you describe is currently not implemented.
> Or as endless loop and you're describing the problem I want to solve
> with other words...

I don't think so. And the behaviour is implemented. Here's an example:

1.) Insert the string "the endles story"
2.) spell check
3.) the spell checker will stop at "endles" and propose "endless"
4.) now change the proposal to "endlesss" and hit "Replace"
5.) "endles" is replaced by "endlesss", but 
6.) the spellchecker does not proceed: it tells me that "endlesss" is wrong 
and proposes again "endless"

I was worried that step 6.) is now skipped, but looking at the whole code, I 
see that there's no need to worry.

> If the speller cannot add the misspelled word to the ignore list or the
> personal dictionary then the recheck will fail again, obviously and the
> user cannot proceed as expected.

I'm not talking about adding or ignoring.

> If you're saying the user should use "Ignore" instead of "Ignore all" in
> this situation (like with 1.6.7?), we should tell Uwe that there
> is no regression and the ticket he made is invalid.

No, I think we talk of two different things. As far as I can see, your 
approach looks sane.

Jürgen

Reply via email to