From: Marcin Borkowski <mbork@mbork.pl>
To: Help Gnu Emacs mailing list <help-gnu-emacs@gnu.org>
Subject: Is there a way to know if this-command altered the buffer?
Date: Wed, 12 May 2021 05:33:30 +0200 [thread overview]
Message-ID: <87tun8wrqt.fsf@mbork.pl> (raw)
Hi all,
I want to run some function in a certain hook. This function will
update some info displayed using an overlay. The info depends on the
buffer contents and is pretty expensive to compute, so I'd like to only
display it if the buffer really changed.
Is there a way to know if `this-command' actually changed the buffer (as
opposed to e.g. point motion)?
TIA,
--
Marcin Borkowski
http://mbork.pl
next reply other threads:[~2021-05-12 3:33 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-12 3:33 Marcin Borkowski [this message]
2021-05-12 4:27 ` Is there a way to know if this-command altered the buffer? Emanuel Berg via Users list for the GNU Emacs text editor
2021-05-12 5:39 ` Marcin Borkowski
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=87tun8wrqt.fsf@mbork.pl \
--to=mbork@mbork.pl \
--cc=help-gnu-emacs@gnu.org \
/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.
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).