From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Michael Heerdegen Newsgroups: gmane.emacs.help Subject: repeatable vs. non-repeatable commands Date: Sat, 24 Jun 2017 08:17:26 +0200 Message-ID: <8760floqo9.fsf@drachen> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1498285086 29452 195.159.176.226 (24 Jun 2017 06:18:06 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 24 Jun 2017 06:18:06 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux) To: Emacs mailing list Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Jun 24 08:18:00 2017 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dOeOM-0007Fp-Si for geh-help-gnu-emacs@m.gmane.org; Sat, 24 Jun 2017 08:17:58 +0200 Original-Received: from localhost ([::1]:38296 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dOeOS-0004TR-3L for geh-help-gnu-emacs@m.gmane.org; Sat, 24 Jun 2017 02:18:04 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:51711) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dOeNx-0004TL-S0 for help-gnu-emacs@gnu.org; Sat, 24 Jun 2017 02:17:34 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dOeNs-0006Iw-QD for help-gnu-emacs@gnu.org; Sat, 24 Jun 2017 02:17:33 -0400 Original-Received: from mout.web.de ([212.227.15.3]:61733) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dOeNs-0006IQ-G4 for help-gnu-emacs@gnu.org; Sat, 24 Jun 2017 02:17:28 -0400 Original-Received: from drachen.dragon ([92.74.161.87]) by smtp.web.de (mrweb001 [213.165.67.108]) with ESMTPSA (Nemesis) id 0Lbrk4-1e5itO2M5c-00jHYw; Sat, 24 Jun 2017 08:17:26 +0200 X-Provags-ID: V03:K0:cH69A0Yla4rAQFIgqtrkdoZV4kSLA8WUJGH1pvYxbeSF1VyYJ01 wi4wd1dqL5yipt/jK55XY1wkVtK8F42JhcqmrxgKs1bayDf/ns7teAnQ91doRtEL9SBvkPK KZ8SUD725qROFogVi2xlAyfyERLQskDra9s+2l+Jadrxf1VD0pf2eYbMu9lgEwKAh1Xk5+Z JSep48cL4hog9jBJ0FStA== X-UI-Out-Filterresults: notjunk:1;V01:K0:asQ8tfd7HyQ=:NIsdd2T10wxsBs4MUx/O6V 4Spppq8eR1VssIcZAZ3e7OMRjpuVU453ZXI5vUjKbpuLFE2tBU7bn8qTTAyAKMONqFRZYa2yW akPSvfbldzAt90y6R6veq35zE+X5Xle8iQvLAKANEDTBiV2Di+1ddpC4ko81fLTkgwX7omcwN ELRxz6LTcOBYPZNPJP9iZFRr8c/b+2JwH60bWYu+eO49sqHRBEuB/j6IuXUQZ/Rp2LKl8Mb5B z4ghUqp31/wVkz0gmACdaiKtr/sI1E7vbQkC+shdhpSrZvjEvorCNgYpgKEJ9bM4U/e2cQz9X mPO1LoccKTjWpjaVSnd3ztmE76OaWVqXjgk7fY4/iVCoRqp32jccWYQiJKsaLZ9Asv4AEmce/ HpS56tfDSRH8GsA0UY5GMynLTi6GLnmOIIhatBOyhhNsqer+scQXN7/MkRO1uAt9uAVku6MMD D1QP0xsfRnPoolg4lDANC2oonH5Iu2hKWFg2VGa06zqFk/f4Wz8wY7vQxCumCe+FjMQsYGk30 wjeKZ1Opf32ovQ2eILRrydvfOd2ommeeAKfroSOL9J8XbhvkRyzBbhsVYKg+qPrsJ0DvVg6iG 9/0eazPPaCVtROxu9jp5qPmnk/GCaV1lU5kxm8VRrcIZS/AvLGdhNat4CZSjn9+hwiIKrXCir OeJI59H2EhOyTigHrMtUFDi5AY4rcPFX+/2uDTJfFgdsQ9d+buqgD0En3TGmUZtezgtWosy5Y /Piz6lxlkqmGCtFORUUyJ1yzY1Xs441uACNo/O2jXT1OFd3mQnVp3ituzj8pLA+JJWPAoCio X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 212.227.15.3 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 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" Xref: news.gmane.org gmane.emacs.help:113549 Archived-At: Hi, in el-search, the default key bindings are all of the form control-shift-letter, like C-S (search-forward), C-R (search-backward), C-A (go to the first match) etc. Since these bindings are not available in a console, I want to provide another configurable binding-scheme of the form prefix+letter, where "prefix" is a prefix key the user can choose. In this case, I want to equip the commands with a transient map so that the prefix has to be given only the first time one of the commands is invoked. For example, if the prefix is meta-s e, meta-s e s s a should invoke a forward search, then go to the next match, and then to the first. The transient map is the same for all prefixes, but in the shift-letter case, it's wrong to use the transient map; it would be surprising when C-S followed by r would search backward instead of stopping the search and invoking the self-insert-command. My question is: is there a way I'm not seeing to achieve this without defining two sets of commands (one set establishing the transient map, another without)? FWIW, my idea was consulting `this-command-keys', but due to bug#27470, I can't use it in my case. Any ideas? Thanks, Michael.