From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Mekeor Melire Newsgroups: gmane.emacs.bugs Subject: bug#74903: [PATCH] Add function to show table of keys when describing keymap variable Date: Tue, 24 Dec 2024 22:55:39 +0000 Message-ID: <87h66s1yj8.fsf@host.mail-host-address-is-not-set> References: <87v7vktu7s.fsf@posteo.de> <86zfkvpqn9.fsf@gnu.org> <87bjxb5yg5.fsf@gmail.com> <37DCBABA-3D38-4FDD-8769-93E3D7F71DCE@posteo.de> Mime-Version: 1.0 Content-Type: text/plain; format=flowed Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="6792"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Mekeor Melire , Robert Pluim , Eli Zaretskii , Stefan Kangas , Andrea Corallo , Stefan Monnier To: 74903@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Dec 24 23:56:24 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1tQDp9-0001bx-MM for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 24 Dec 2024 23:56:23 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tQDot-00023U-Qt; Tue, 24 Dec 2024 17:56:08 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tQDoq-00023C-8i for bug-gnu-emacs@gnu.org; Tue, 24 Dec 2024 17:56:04 -0500 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tQDop-0003Vv-Vi; Tue, 24 Dec 2024 17:56:04 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:Date:References:In-Reply-To:From:To:Subject; bh=Gipfu9Bh6WhttNJjSHZDx7bqInxeTt2DJ4+qGOZlmvA=; b=a2myYsM5Oyxm+az3zRXgCKDd+iuXd6cIIYVV1jeL9bcEBtM+CWYwGV2UllCajVO2vFLj+9H9d4GTQVqNira+F2yL+w2C/+Mef6nRIwlioQi9xtT+zEFnyvpi2cRV3OLnuhUMC9eqtul+9pNYfy5HPKqB1hqQUB/+IU5kykBBLNAvnK9Eoeh2AXmjh2d3ECnI/Z1uKvaL2cgm2tZ8PdWvXz69F60gJ+5V2xCnsmkX+74M9aS9UNVumGwKENhTQN8P2/scduhUvhYutKiBOBn5jkXgP9Ovr0T9gp0Kbw1ZsC7FAbk5uo+ZYU54rcdD3VC1kvuxIQFyAGC+UmB0ywGJSA==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tQDon-0004Bh-NR; Tue, 24 Dec 2024 17:56:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Mekeor Melire Original-Sender: "Debbugs-submit" Resent-CC: mekeor@posteo.de, rpluim@gmail.com, eliz@gnu.org, stefankangas@gmail.com, acorallo@gnu.org, monnier@iro.umontreal.ca, bug-gnu-emacs@gnu.org Resent-Date: Tue, 24 Dec 2024 22:56:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 74903 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch X-Debbugs-Original-Xcc: Mekeor Melire , Robert Pluim , Eli Zaretskii , Stefan Kangas , Andrea Corallo , Stefan Monnier Original-Received: via spool by 74903-submit@debbugs.gnu.org id=B74903.173508095716087 (code B ref 74903); Tue, 24 Dec 2024 22:56:01 +0000 Original-Received: (at 74903) by debbugs.gnu.org; 24 Dec 2024 22:55:57 +0000 Original-Received: from localhost ([127.0.0.1]:35290 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tQDoj-0004BP-0e for submit@debbugs.gnu.org; Tue, 24 Dec 2024 17:55:57 -0500 Original-Received: from mout02.posteo.de ([185.67.36.66]:53343) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tQDoe-0004B4-B4 for 74903@debbugs.gnu.org; Tue, 24 Dec 2024 17:55:55 -0500 Original-Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id 73A05240101 for <74903@debbugs.gnu.org>; Tue, 24 Dec 2024 23:55:44 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.de; s=2017; t=1735080945; bh=VuRy4Ys+sICgt/Xw2pQtzszE/ViqdAlLAH8UI+zwPjg=; h=From:To:Subject:Date:Message-ID:MIME-Version:Content-Type:From; b=OhhUka7DUF1kl3IKXcIwy+bBnQgeU6yEmGgKKhPOchT1OR6C1VZRT6WFYpHVAL+in YvJ4Hs3VPuPaUScGTxKfvVU9ypxGQ1E8ma98A/7nnzZ+ngH2be+BHBYJPvm75PREv+ pkOOVISWbGOtqkO9W8Pos/MdvEnEkg5m5rJZA0xZDaPRgharqGR3CqCVoNafxqjOyr hIkpX1HNqSU+5UaEB+s/hlZ1il8T3OnI8ZLFXtOpP2FDnrdUQjZdpfH2rwEHOsnGcZ PCbGyg+GAsT5ycLiz/8AyAabvaeLeT9/P6M9KCN/xLI0ptyvtXSmgGyVt0z1VY82uO E46SS+OHcPfSg== Original-Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4YHqxD4P72z9rxK for <74903@debbugs.gnu.org>; Tue, 24 Dec 2024 23:55:44 +0100 (CET) In-Reply-To: (Stefan Monnier's message of "Mon, 16 Dec 2024 22:03:22 -0500") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:297703 Archived-At: I had accidentally sent following email only to Stefan Monnier rather than the whole list. I'm thus sending it again. On Mon, 16 Dec 2024 22:03:22 -0500, Stefan Monnier said: > The table is a bit redundant with the s-exp representation and > I'm not sure we want to spend all this time&space printing out a > large keymap, but maybe we could use the > `help-fns-describe-variable-functions` mechanism to add a > one-liner that can be clicked to get to the keymap-specific > description, a bit like Custom vars have a "You can customize > this variable" link. WDYT? I agree that there's redundancy. But since adding the function `help-fns-keymap-key-bindings' from my patch to `help-fns-describe-variable-functions` would be opt-in, it'd be up to the user to decide between redundancy and convenience. Nevertheless, I like your idea of a clickable button, e.g. worded "View this keymap as a table" in the *Help* buffer. Let me continue your comparison to the "You can customize this variable" button by noting that its command, `help-customize', is also bound to "c" in Help-Mode. I'd also like a key binding for "View this keymap as a table", e.g. "k". So, these key sequences would result in the same state: C-h v foo-map RET k M-x describe-keymap foo-map RET But we can build up this idea further: What if these would also result in the same state? (`ido-mode' is both a variable and a function.) C-h f ido-mode RET o C-h v ido-mode RET o C-h o ido-mode RET And also: C-h v ido-mode RET f C-h f ido-mode RET What do you think about enabling users to easily "effectively switch" between describe-* commands in this way?