From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Kaushal Modi Newsgroups: gmane.emacs.devel Subject: Re: Key binding popup interface Date: Tue, 12 Dec 2017 21:28:01 +0000 Message-ID: References: <87r2s3ctxh.fsf@ericabrahamsen.net> <87d13m3jt2.fsf@gmx.us> <87efo2wf0s.fsf@ericabrahamsen.net> <87y3m8s7ym.fsf@gmx.us> <87fu8gwfbr.fsf@nicolasgoaziou.fr> <87k1xs2h0h.fsf@gmx.us> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="001a114075daeed16905602b53ec" X-Trace: blaine.gmane.org 1513114102 14251 195.159.176.226 (12 Dec 2017 21:28:22 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 12 Dec 2017 21:28:22 +0000 (UTC) Cc: emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Dec 12 22:28:18 2017 Return-path: Envelope-to: ged-emacs-devel@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 1eOs65-0003Kk-60 for ged-emacs-devel@m.gmane.org; Tue, 12 Dec 2017 22:28:17 +0100 Original-Received: from localhost ([::1]:60602 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eOs6A-0000Gv-Mz for ged-emacs-devel@m.gmane.org; Tue, 12 Dec 2017 16:28:22 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:58163) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eOs61-0000Fa-Lc for emacs-devel@gnu.org; Tue, 12 Dec 2017 16:28:14 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eOs60-0005ML-Cs for emacs-devel@gnu.org; Tue, 12 Dec 2017 16:28:13 -0500 Original-Received: from mail-yw0-x235.google.com ([2607:f8b0:4002:c05::235]:45372) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1eOs60-0005Lk-7Z for emacs-devel@gnu.org; Tue, 12 Dec 2017 16:28:12 -0500 Original-Received: by mail-yw0-x235.google.com with SMTP id y187so86575ywd.12 for ; Tue, 12 Dec 2017 13:28:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=5gBv4Dh7iFNPJWIqkHY1JtGkxvtKkCi3GKZHFXkCclo=; b=sxipfj7n2ZOLzO/V7YRuhqo6Eo7OKhl9m+ZhXcXTJTnzzmedmoYplMbbkRlnRaOT8K wqxD2YUsJFwJCRwVZTCJIz3NZb6OLGD+wSLivRERo4tbQdgxWwnY3BT151LzfCA0UNJU cPLhUtBhxMJMK6JXQyZWVYWqLMHVKoHik86ao7q5jE/pXxnwR2VlF/gcxyj7XC2aPo/6 i81nsNvzxwNdBWN0e/NLycyZPKSRZdN1TX7ntmfMJHGaNktltMc4ZyuXD9MKZFRiqy9D mkGXkeRk7uANUhUDZHECJqnM7yB59SeonK86UMq16l4S8z+NsjmD7vtidoWKO1/WvVQA wwIw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=5gBv4Dh7iFNPJWIqkHY1JtGkxvtKkCi3GKZHFXkCclo=; b=fVd5L9YzHTDOd+18YmAh1IndZPD+sB/TlmAa9zSsFJPUz1g7rtS+qxYC3HEoToP4Z3 O3fQwJdXNn/EBDDJk5Jvb5Xab4kaSRvmYwJXzSYkBbLnBSna0jS3+bNwQjSsMdxfituB UiUKQEE4romeRmKyNvtkJbLz3eJa5D0eH1FyscRPMDTy+FnVh8J48/2JwgYG8v+ufKjc 5GIfj99Ac6vxC/pK8xJObPfErw/qrrMAMRAz8RXmOHjYGwvNPi/UHQWPAh70JBqLof3r O+F6nqNk9yTPoA6a28Dh6AaJcjUjkAc9bAR0HEroeLax5O/vefPDSLuhlauG6+v34SJE Sw0w== X-Gm-Message-State: AKGB3mLZo3vUrGkYnQZQm/20lFldJQqGeJP4BCic26vQUqDgcVPCXVnk ktKYbyyCte/7qlFMISswAEpnPQkKJc9zoH0kTVU= X-Google-Smtp-Source: ACJfBotV2mYZDNFl5AIy904ShmwfuCjz2szayeVU5O8ComywEngPmVeKOtEcOGiKLjiFJdh8S/Lqs3w+xIKEuEcOVhM= X-Received: by 10.129.52.9 with SMTP id b9mr219507ywa.54.1513114091571; Tue, 12 Dec 2017 13:28:11 -0800 (PST) In-Reply-To: X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4002:c05::235 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:220964 Archived-At: --001a114075daeed16905602b53ec Content-Type: text/plain; charset="UTF-8" On Tue, Dec 12, 2017 at 4:19 PM Stefan Monnier wrote: > > For instance, I have a hydra to insert different Org blocks in org-mode, > > and looks like this: > > [image: image.png] > > [ Hmm... Gnus here doesn't seem to provide any way for me to see > this image. ] > Sorry about that.. don't those images show up as attachments? They show up on the mailing list page fine. Here are 2 messages where I pasted images in this thread: - http://lists.gnu.org/r/emacs-devel/2017-12/msg00392.html - http://lists.gnu.org/r/emacs-devel/2017-12/msg00395.html This sounds a bit like the primitive "hierarkey" feature which I used in > PCL-CVS. Basically there I defined a sub-keymap bound to `d` with > bindings like: > > (?= . ("diff" . cvs-mode-diff)) > (?2 . ("other" . cvs-mode-diff-other)) > (?d . ("diff" . cvs-mode-diff)) > (?v . ("vendor" . cvs-mode-diff)) > ... > > so after hitting `d` Emacs shows in the each area something like > "Diff: vendor, diff, = = diff, 2 = other, ...". > I had not heard of that! This is a very old feature implemented in the C code (src/keyboard.c) > and very little used. > > It would be good to replace it with a more powerful feature implemented > in Elisp and used more widely. > That's a +1 for hydra? :) You can check out more examples of hydra on its Wiki[1]. I have quite a few hydra examples in my emacs config too[2]. [1]: https://github.com/abo-abo/hydra/wiki/Emacs [2]: https://github.com/kaushalmodi/.emacs.d/search?l=Emacs+Lisp&q=defhydra -- Kaushal Modi --001a114075daeed16905602b53ec Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
On Tue, Dec 12= , 2017 at 4:19 PM Stefan Monnier <monnier@iro.umontreal.ca> wrote:
> For instance, I have a hydra to insert different Org blocks= in org-mode,
> and looks like this:
> [image: image.png]

[ Hmm... Gnus here doesn't seem to provide any way for me to see
=C2=A0 this image.=C2=A0 ]

Sorry about = that.. don't those images show up as attachments? They show up on the m= ailing list page fine. Here are 2 messages where I pasted images in this th= read:


This sounds a bit like the primitive "hierarkey" feature which I = used in
PCL-CVS.=C2=A0 Basically there I defined a sub-keymap bound to `d` with
bindings like:

=C2=A0 =C2=A0 =C2=A0 =C2=A0(?=3D . ("diff" . cvs-mode-diff))
=C2=A0 =C2=A0 =C2=A0 =C2=A0(?2 . ("other" . cvs-mode-diff-other))=
=C2=A0 =C2=A0 =C2=A0 =C2=A0(?d . ("diff"=C2=A0 . cvs-mode-diff))<= br> =C2=A0 =C2=A0 =C2=A0 =C2=A0(?v . ("vendor"=C2=A0 . cvs-mode-diff)= )
=C2=A0 =C2=A0 =C2=A0 =C2=A0...

so after hitting `d` Emacs shows in the each area something like
"Diff: vendor, diff, =3D =3D diff, 2 =3D other, ...".

I had not heard of that!

This is a very old feature implemented in the C code (src/keyboard.c)
and very little used.

It would be good to replace it with a more powerful feature implemented
in Elisp and used more widely.

That'= ;s a=C2=A0+1 for hydra? :)

You can check out more = examples of hydra on its Wiki[1]. I have quite a few hydra examples in my e= macs config too[2].

--

Kaushal Modi

--001a114075daeed16905602b53ec--