From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Artur Malabarba Newsgroups: gmane.emacs.bugs Subject: bug#22107: 25.1; Wrong docstring for this-single-command-keys Date: Fri, 11 Dec 2015 15:39:46 +0000 Message-ID: References: Reply-To: bruce.connor.am@gmail.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: ger.gmane.org 1449854906 14575 80.91.229.3 (11 Dec 2015 17:28:26 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 11 Dec 2015 17:28:26 +0000 (UTC) Cc: 22107@debbugs.gnu.org To: Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Dec 11 18:28:15 2015 Return-path: Envelope-to: geb-bug-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 1a7RUN-0002HP-3G for geb-bug-gnu-emacs@m.gmane.org; Fri, 11 Dec 2015 18:28:15 +0100 Original-Received: from localhost ([::1]:48794 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a7RUM-0004lu-64 for geb-bug-gnu-emacs@m.gmane.org; Fri, 11 Dec 2015 12:28:14 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:50102) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a7RUD-0004c9-Hx for bug-gnu-emacs@gnu.org; Fri, 11 Dec 2015 12:28:10 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a7RUA-0004N5-AQ for bug-gnu-emacs@gnu.org; Fri, 11 Dec 2015 12:28:05 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:57646) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a7RUA-0004N1-7M for bug-gnu-emacs@gnu.org; Fri, 11 Dec 2015 12:28:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84) (envelope-from ) id 1a7RUA-0007dm-2t for bug-gnu-emacs@gnu.org; Fri, 11 Dec 2015 12:28:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Artur Malabarba Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 11 Dec 2015 17:28:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 22107 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 22107-submit@debbugs.gnu.org id=B22107.144985484129291 (code B ref 22107); Fri, 11 Dec 2015 17:28:02 +0000 Original-Received: (at 22107) by debbugs.gnu.org; 11 Dec 2015 17:27:21 +0000 Original-Received: from localhost ([127.0.0.1]:40669 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1a7RTV-0007cN-DO for submit@debbugs.gnu.org; Fri, 11 Dec 2015 12:27:21 -0500 Original-Received: from mail-lf0-f53.google.com ([209.85.215.53]:36339) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1a7RTU-0007c8-3i for 22107@debbugs.gnu.org; Fri, 11 Dec 2015 12:27:20 -0500 Original-Received: by lfed137 with SMTP id d137so32499573lfe.3 for <22107@debbugs.gnu.org>; Fri, 11 Dec 2015 09:27:14 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:reply-to:sender:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=izPHIOLc7PqfciUtzl9WBReD2B3EBEzXHNps34TPqCI=; b=P1zsbM89N6YQb3VI41bGap68gXoxFIbva86FFDuSHqZrkeHPEZCyOXhbxYSHpdFthO EGwEEj3/KQ5LRQF1p53kfFvUgzI81piidq0/3kGB90AWXW0vtYckm3irIppBXAxOUn5E bZchBPZZ/MwOEgyJvYmQLWXsUlhJNDeQFW4Y4jfK/eWrokiPxsrBTC14h/rE56Jp4e3i L1YDtmq/k4pC4jYvhnuFZcvDC3nUj4iWXn1kcZiy2nuCbsC/lUsYRf1z4BfcO5Pqg7QZ XUBkrbcA5KyIfuddGAl2MX2C9cLUyuF5TiOydpFO5C0+P1gDg30nh2Vc0FPOZmOMTP9w c2Zg== X-Received: by 10.25.20.217 with SMTP id 86mr8075955lfu.164.1449848386235; Fri, 11 Dec 2015 07:39:46 -0800 (PST) Original-Received: by 10.112.202.99 with HTTP; Fri, 11 Dec 2015 07:39:46 -0800 (PST) In-Reply-To: X-Google-Sender-Auth: xAKrVS4gJf53AYAT3-kkhfnuerM X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 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.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:109855 Archived-At: 2015-12-11 14:44 GMT+00:00 Stefan Monnier : >>> Indeed, C-u is now a completely normal command so there's no special >>> handling of "prefix commands" for this-command-keys. >>> Could you tel us where that caused a problem for you? >> I wrote a package for use in screencasts, which displays the key for >> some commands when you invoke them. And I wanted it to show prefix >> args too. > > Could you give some details? More specifically, doesn't the screen-cast > already give you the C-u when the prefix command itself is run? It can be made to, yes. But I wanted the C-u it to be displayed as part of the following command. The point of this little package is that it doesn't display every single key combo you use. It only displays the keybind of a few commands that you specify in advance (so it only shows the commands you're trying to teach). So you run something like (display-keys-for-commands '(eval-last-sexp eval-buffer eval-defun)). From there on, wherever you type C-x C-e, a small frame will popup saying: eval-last-sexp C-x C-e (where C-x C-e is in a big bright font). Now I also want to teach viewers that hitting C-u C-x C-e will insert the results of evaluation. I could add `universal-argument' to that list of commands for which it will show the key, but then it will report that C-u was pressed even when it is pressed before some command that I don't care about (like C-n or C-p). This is a sensible behavior given that C-u is a command like any other, but it would be confusing for viewers who don't understand this technicality. Right now, I've just patched my own code to display something like this in that situation (and I'm happy with it): eval-last-sexp (with prefix) C-u C-x C-e