unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Jambunathan K <kjambunathan@gmail.com>
To: help-gnu-emacs@gnu.org
Subject: Re: Character repeation detection
Date: Sun, 09 Mar 2014 11:38:39 +0530	[thread overview]
Message-ID: <878usjewew.fsf@gmail.com> (raw)
In-Reply-To: loom.20140309T064012-622@post.gmane.org




Tom <adatgyujto@gmail.com> writes:

> Is there a function or package to detect if a character is typed
> repeatedly? E.g. if a is typed 3 or more times in a row (aaa...)
> then call a function.
>
> Is there an existing solution for this?

    M-s h r \(.\)\1 RET

    (highlight-regexp "\\(.\\)\\1" (quote highlight))

>
> It would even be better if it had repetition suppression, that is
> if I leave my finger on a key so I type a string of a certain character
> (aaaaaaaaaaaaaaaaaaaaaaaaaaaaa) then after the first 3 repetition
> the function is called and the rest of the repeated characters are
> removed from the keyboard buffer.




  reply	other threads:[~2014-03-09  6:08 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-09  5:47 Character repeation detection Tom
2014-03-09  6:08 ` Jambunathan K [this message]
2014-03-09  7:08   ` Tom
2014-03-09  7:12     ` Tom
2014-03-09 13:47       ` Marcin Borkowski
2014-03-09 15:29       ` Jambunathan K
2014-03-09 16:46         ` Tom
2014-03-09 17:13           ` Marcin Borkowski
2014-03-09 18:20             ` Andreas Röhler
2014-03-09 18:39             ` Tom
2014-03-09 20:20           ` Tom
2014-03-10  1:20           ` Stefan Monnier
     [not found]         ` <mailman.16788.1394383649.10748.help-gnu-emacs@gnu.org>
2014-03-09 17:46           ` Dan Espen
2014-03-09 18:42             ` Tom
2014-03-10  1:15           ` Joost Kremers
2014-03-10  1:59       ` Eric Abrahamsen
2014-03-09 16:29 ` Yuri Khan
     [not found] ` <mailman.16786.1394382568.10748.help-gnu-emacs@gnu.org>
2014-03-09 17:39   ` Pascal J. Bourguignon

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=878usjewew.fsf@gmail.com \
    --to=kjambunathan@gmail.com \
    --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).