From: Eli Zaretskii <eliz@gnu.org>
To: "Clément Pit-Claudel" <cpitclaudel@gmail.com>
Cc: 26525@debbugs.gnu.org
Subject: bug#26525: `sit-for' in Flyspell slows typing down, hogs 90% of CPU
Date: Mon, 17 Apr 2017 10:14:17 +0300 [thread overview]
Message-ID: <83r30recae.fsf@gnu.org> (raw)
In-Reply-To: <5fd6562f-6190-5c3c-34c1-24370e9937be@gmail.com> (message from Clément Pit-Claudel on Sat, 15 Apr 2017 16:33:56 -0400)
> From: Clément Pit-Claudel <cpitclaudel@gmail.com>
> Date: Sat, 15 Apr 2017 16:33:56 -0400
>
> The relevant piece of code seems to be this:
>
> (cond
> ((get this-command 'flyspell-deplacement)
> (not (eq flyspell-previous-command this-command)))
> ((get this-command 'flyspell-delayed)
> ;; The current command is not delayed, that
> ;; is that we must check the word now.
> (and (not unread-command-events)
> (sit-for flyspell-delay)))
> (t t)))
>
> But the condition and the comment seem at odds, and it doesn't say much about why it calls `sit-for`.
I'm not quite sure what needs to be explained. I think the doc string
of flyspell-delay and flyspell-default-delayed-commands tell the whole
story; if something is unclear there, please say what is unclear.
If you want to see this feature in action, turn on Flyspell, then type
something like "ssss", and then wait _without_ typing any non-word
character. You will see that the mis-spelled word is marked only
after 3 sec, the default value of flyspell-delay. Then contrast that
with the same word with a space typed after it.
IOW, this is a feature designed to avoid annoying users who type
slowly or make short breaks after typing only part of a word.
next prev parent reply other threads:[~2017-04-17 7:14 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-15 20:28 bug#26525: `sit-for' in Flyspell slows typing down, hogs 90% of CPU Clément Pit-Claudel
2017-04-15 20:33 ` Clément Pit-Claudel
2017-04-17 7:14 ` Eli Zaretskii [this message]
2017-04-17 13:29 ` Clément Pit-Claudel
2017-04-17 14:25 ` Eli Zaretskii
2017-04-17 15:36 ` Clément Pit-Claudel
2020-08-13 1:41 ` Stefan Kangas
2017-10-17 12:07 ` Damien Cassou
2020-08-28 11:49 ` Stefan Kangas
2020-08-28 12:35 ` Damien Cassou
2020-08-28 18:40 ` Clément Pit-Claudel
2020-08-29 16:27 ` Stefan Kangas
2020-08-29 18:10 ` Clément Pit-Claudel
2020-09-02 23:15 ` Nick H
2020-09-03 10:19 ` Stefan Kangas
2020-09-04 1:01 ` Nick Helm
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=83r30recae.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=26525@debbugs.gnu.org \
--cc=cpitclaudel@gmail.com \
/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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.