[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ispell language per buffer, not for all buffers

From: Eli Zaretskii
Subject: Re: ispell language per buffer, not for all buffers
Date: Fri, 23 Nov 2001 09:53:54 +0200

> From: address@hidden (Pavel =?iso-8859-2?q?Jan=EDk?=)
> Date: Thu, 22 Nov 2001 20:34:06 +0100
>    From: Eli Zaretskii <address@hidden>
>    Date: Thu, 22 Nov 2001 18:47:09 +0200 (IST)
>    > I think restarting Ispell each time the user switches buffers is not a 
>    > good idea, since doing so loses the ``spelling history'': the words you 
>    > told Ispell to accept and maybe also those you told Ispell to insert 
> into 
>    > the private dictionary.
> You will not loose words when restarting ispell, because restart means you
> are using different dictionary (so word in previous ie. different personal
> directory are useless).

They are useless in the buffer that uses a different language, but
they are not useless in the buffer you were before.

Imagine the following situation: you have two buffers, one in English,
the other in Russian.  You spell-check the English buffer, then go to
the Russian one and spell-check it as well.  Then you go back to the
English buffer, add some text and want to spell-check the result.  But
Ispell was restarted (twice, actually), so it doesn't remember all the
words you told it to accept during the first spell-check.

This problem can be taken care of if we reuse the code in ispell.el
used by the MS-DOS port of Emacs.  Since that port doesn't support
async subprocesses, it has no alternative but to invoke Ispell anew
for every line of text ispell.el wants to spell-check.  To avoid
losing what I called ``the spelling history'', ispell.el saves all
the commands that influence that history in a special buffer, and
then rams them down Ispell's throat each time it is invoked, before
feeding it with the next line.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]