From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#29478: [Patch] bug#29478: 26.0.90; `C-h k' followed by mouse clicks no longer shows down event Date: Sun, 24 Dec 2017 10:41:55 -0500 Message-ID: References: <83o9ni3l3i.fsf@gnu.org> <83bmji2xye.fsf@gnu.org> <83tvwzubez.fsf@gnu.org> <20171222220549.GC8072@ACM> <833741lr0t.fsf@gnu.org> <20171223111726.GA6618@ACM> <20171223210407.GC6618@ACM> <20171224114836.GB8145@ACM> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1514130075 9657 195.159.176.226 (24 Dec 2017 15:41:15 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 24 Dec 2017 15:41:15 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) Cc: 29478@debbugs.gnu.org, npostavs@users.sourceforge.net To: Alan Mackenzie Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Dec 24 16:41:10 2017 Return-path: Envelope-to: geb-bug-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 1eT8Ok-00028w-C5 for geb-bug-gnu-emacs@m.gmane.org; Sun, 24 Dec 2017 16:41:10 +0100 Original-Received: from localhost ([::1]:55666 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eT8Qi-0001Pj-PL for geb-bug-gnu-emacs@m.gmane.org; Sun, 24 Dec 2017 10:43:12 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:37278) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eT8Qb-0001P1-Nz for bug-gnu-emacs@gnu.org; Sun, 24 Dec 2017 10:43:06 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eT8QY-0008M2-Kc for bug-gnu-emacs@gnu.org; Sun, 24 Dec 2017 10:43:05 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:42112) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1eT8QY-0008La-Hp for bug-gnu-emacs@gnu.org; Sun, 24 Dec 2017 10:43:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1eT8QY-00010H-8p for bug-gnu-emacs@gnu.org; Sun, 24 Dec 2017 10:43:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 24 Dec 2017 15:43:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 29478 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: confirmed Original-Received: via spool by 29478-submit@debbugs.gnu.org id=B29478.15141301243779 (code B ref 29478); Sun, 24 Dec 2017 15:43:02 +0000 Original-Received: (at 29478) by debbugs.gnu.org; 24 Dec 2017 15:42:04 +0000 Original-Received: from localhost ([127.0.0.1]:50793 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eT8Pa-0000yr-GS for submit@debbugs.gnu.org; Sun, 24 Dec 2017 10:42:02 -0500 Original-Received: from chene.dit.umontreal.ca ([132.204.246.20]:58899) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eT8PW-0000yO-BS for 29478@debbugs.gnu.org; Sun, 24 Dec 2017 10:42:00 -0500 Original-Received: from ceviche.home (lechon.iro.umontreal.ca [132.204.27.242]) by chene.dit.umontreal.ca (8.14.7/8.14.1) with ESMTP id vBOFftZL018680; Sun, 24 Dec 2017 10:41:55 -0500 Original-Received: by ceviche.home (Postfix, from userid 20848) id 209356630A; Sun, 24 Dec 2017 10:41:55 -0500 (EST) In-Reply-To: <20171224114836.GB8145@ACM> (Alan Mackenzie's message of "Sun, 24 Dec 2017 11:48:36 +0000") X-NAI-Spam-Flag: NO X-NAI-Spam-Threshold: 5 X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 2 Rules triggered EDT_SA_DN_PASS=0, RV6186=0 X-NAI-Spam-Version: 2.3.0.9418 : core <6186> : inlines <6282> : streams <1774047> : uri <2556623> 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" Xref: news.gmane.org gmane.emacs.bugs:141449 Archived-At: >> What do you guys think? > It's a long patch. Any chance of you giving a brief summary of what it > does and what it's for, how it differs from what's already there, and so > on? The core part is `help-read-key-sequence` which is changed to: Return a list of elements of the form (SEQ . RAW-SEQ), where SEQ is a key sequence, and RAW-SEQ is its untranslated form. If NO-MOUSE-MOVEMENT is non-nil, ignore key sequences starting with `mouse-movement' events." and which just keeps calling read-key-sequence as long as: ;; Read at least one key-sequence. (or (null key-list) ;; After a down event, also read the (presumably) following ;; up-event. (memq 'down last-modifiers) ;; After a click, see if a double click is on the way. (and (memq 'click last-modifiers) (not (sit-for (/ double-click-time 1000.0) t)))) So when you do `C-h k` followed by a triple click, help-read-key-sequence will can return a list of 6 elements (3 down events and 3 up events). describe-key(-briefly) are changed to just loop over all the key sequences returned. > It's also refreshing to see a context diff every now and then. :-) The new code share too little with the old code, so I found the unified diff unreadable. Stefan