From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dan Espen Newsgroups: gmane.emacs.help Subject: Re: Character repeation detection Date: Sun, 09 Mar 2014 13:46:21 -0400 Organization: A noiseless patient Spider Message-ID: References: <878usjewew.fsf@gmail.com> <87eh2bmlvd.fsf@gmail.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1394387412 31189 80.91.229.3 (9 Mar 2014 17:50:12 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 9 Mar 2014 17:50:12 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sun Mar 09 18:50:21 2014 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1WMhrh-0001DZ-ET for geh-help-gnu-emacs@m.gmane.org; Sun, 09 Mar 2014 18:50:21 +0100 Original-Received: from localhost ([::1]:44981 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WMhrh-0002tK-1Z for geh-help-gnu-emacs@m.gmane.org; Sun, 09 Mar 2014 13:50:21 -0400 Original-Path: usenet.stanford.edu!news.kjsl.com!feeder.erje.net!us.feeder.erje.net!newsfeed.fsmpi.rwth-aachen.de!eternal-september.org!feeder.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 38 Injection-Info: mx05.eternal-september.org; posting-host="189748f827f5005aa08ac3cba2786117"; logging-data="9244"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19U6LshNfuFoP6pj11/yuT20yEeedbuwps=" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) Cancel-Lock: sha1:jtmnxU415MXVNxzZ78glfvGL0gc= sha1:omiNVc5ZcHSeulET2fEBK9T9SRA= Original-Xref: usenet.stanford.edu gnu.emacs.help:204073 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:96343 Archived-At: Tom writes: > Jambunathan K gmail.com> writes: > >> >> Here is a quick one that checks for 2 characters in a row. >> >> Are you sure you don't want flyspell-mode and only this. What is your >> usecase. Why would you want this? > > I want to use it as a hotkey. > > It occured to me it's very unusual to type the same character 3 > times in a row. Two can occur in words, but 3 practically never. > > Therefore it could be used as a single key hotkey in text buffers > where otherwise you use the characters to type. I have a KVM that uses 3 presses of Ctrl as a way of sending commands to the KVM. 3 presses followed by a key that represents the command. I do sometimes accidentally hit Ctrl 3 times but the KVM starts flashing the keyboard LED lights so it's easy to know I've hit the key by accident. > For example, I want to invoke occur. I press o and keep it pressed. > After auto repeat types 3 o characters this function kicks in, removes > the 3 typed Os from the buffer, removes the additional Os from the > keyboard buffer (if I kept it pressed for two long) and calls occur. > > It seems to me it would be more convenient than typing multikey > hotkeys and it would give lots of new free bindings in addition to > the existing ones. It would, but I suspect the modes that have a lot of key bindings using typing keys (like Dired and buffer list) might present a problem. -- Dan Espen