unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Eric S Fraga <e.fraga@ucl.ac.uk>
To: help-gnu-emacs@gnu.org
Subject: Re: How to detect words being added and removed to a buffer in a minor mode?
Date: Mon, 21 Nov 2022 09:39:38 +0000	[thread overview]
Message-ID: <87zgckhcit.fsf@ucl.ac.uk> (raw)
In-Reply-To: t1zqzs6wG1IQq-vzClDIGFKijMZwrmAnngZTYUBcIrKD8FFTEpSneUkKtSdu3j5vhen_HYX_9eWkdjlJkn9vMUE4sUBnynAzsXM5N7pD_Cg=@dpisarenko.com

On Saturday, 19 Nov 2022 at 20:44, Dmitrii Pisarenko wrote:
> 1. How can I create an "event listener" (sorry for the non-Emacsian
> terminology) which would be called whenever the user types something
> in the buffer?

Naïvely (i.e. I may be totally ignorant of a proper solution), there is
post-command-hook which can be used to process every single key event.

-- 
Eric S Fraga via gnus (Emacs 29.0.50 2022-11-13) on Debian 11.4




  reply	other threads:[~2022-11-21  9:39 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-19 20:44 How to detect words being added and removed to a buffer in a minor mode? Dmitrii Pisarenko
2022-11-21  9:39 ` Eric S Fraga [this message]
2022-11-21 10:08   ` Jean Louis
2022-11-21 10:34     ` Emanuel Berg
2022-11-21 11:27     ` Eric S Fraga
2022-11-21 12:40       ` Emanuel Berg
2022-11-21 17:17     ` Marcin Borkowski
2022-11-21 17:21       ` Marcin Borkowski
2022-11-21 18:56       ` [External] : " Drew Adams
2022-11-22 15:33       ` Emanuel Berg
2022-11-26  6:14         ` Marcin Borkowski
2022-11-26 14:51           ` Emanuel Berg
  -- strict thread matches above, loose matches on Subject: below --
2022-11-19 20:45 Pravles Redneсkoff via Users list for the GNU Emacs text editor
2022-11-20  3:10 ` Bob Newell

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=87zgckhcit.fsf@ucl.ac.uk \
    --to=e.fraga@ucl.ac.uk \
    --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).