From: Eli Zaretskii <eliz@gnu.org>
To: Titus von der Malsburg <malsburg@posteo.de>
Cc: emacs-devel@gnu.org
Subject: Re: Changing dictionary while flyspell-buffer is running
Date: Wed, 20 Feb 2019 19:05:11 +0200 [thread overview]
Message-ID: <83zhqqgzlk.fsf@gnu.org> (raw)
In-Reply-To: <874l8ztmgk.fsf@posteo.de> (message from Titus von der Malsburg on Tue, 19 Feb 2019 23:58:19 +0100)
> From: Titus von der Malsburg <malsburg@posteo.de>
> Date: Tue, 19 Feb 2019 23:58:19 +0100
>
> My question relates to flyspell-buffer. When flyspell-buffer detects an
> incorrect word, language guessing is activated via
> fylspell-incorrect-hook but it’s not clear to me how to proceed next. I
> think I’d have to kill the running ispell/aspell/hunspell process and
> restart with the new dictionary from where we left off. Is there any
> infrastructure in Flyspell that makes this relatively easy and safe? I
> had a look at the code and it seems that there is quite a bit of state
> in various places, so it’s probably not just a matter of killing a
> process, and doing things cleanly might require better understanding of
> the internals than I have. Any advice one how to approach this would be
> appreciated.
There is already a command ispell-change-dictionary which does
everything that needs to be done when a dictionary is changed. I
think you just need to invoke it. If doing that during
flyspell-buffer somehow causes trouble, then do it after exiting
flyspell-buffer, then reinvoke flyspell-buffer or something.
next prev parent reply other threads:[~2019-02-20 17:05 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-02-19 22:58 Changing dictionary while flyspell-buffer is running Titus von der Malsburg
2019-02-20 17:05 ` Eli Zaretskii [this message]
[not found] ` <87y36as44p.fsf@posteo.de>
[not found] ` <83o976gvd2.fsf@gnu.org>
[not found] ` <87h8cxsed3.fsf@posteo.de>
2019-02-21 14:59 ` Eli Zaretskii
2019-02-21 3:26 ` Richard Stallman
2019-02-21 3:46 ` Eli Zaretskii
2019-02-21 8:34 ` Titus von der Malsburg
2019-02-21 14:53 ` Eli Zaretskii
2019-02-21 19:42 ` Joost Kremers
2019-02-21 20:09 ` Eli Zaretskii
2019-02-21 21:19 ` Titus von der Malsburg
2019-02-22 7:10 ` Eli Zaretskii
2019-02-22 9:57 ` Titus von der Malsburg
2019-02-22 10:32 ` Eli Zaretskii
2019-02-23 15:24 ` Stefan Monnier
2019-02-21 8:29 ` Titus von der Malsburg
2019-02-21 13:12 ` Clément Pit-Claudel
2019-02-22 2:06 ` Richard Stallman
2019-02-22 9:27 ` Titus von der Malsburg
2019-02-28 12:36 ` Titus von der Malsburg
2019-02-28 17:50 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=83zhqqgzlk.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=emacs-devel@gnu.org \
--cc=malsburg@posteo.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).