From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: James Bunton Newsgroups: gmane.emacs.bugs Subject: bug#25715: 25.1; goto-address-mode with custom keymap yanks text on click Date: Tue, 14 Feb 2017 12:31:04 +1100 Message-ID: <1487035864.2350856.880060792.312606B0@webmail.messagingengine.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Trace: blaine.gmane.org 1487036591 9570 195.159.176.226 (14 Feb 2017 01:43:11 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 14 Feb 2017 01:43:11 +0000 (UTC) To: 25715@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Feb 14 02:43:06 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 1cdS94-0002Cw-Jt for geb-bug-gnu-emacs@m.gmane.org; Tue, 14 Feb 2017 02:43:06 +0100 Original-Received: from localhost ([::1]:60420 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cdS9A-0003FV-EE for geb-bug-gnu-emacs@m.gmane.org; Mon, 13 Feb 2017 20:43:12 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:52592) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cdS93-0003FN-VU for bug-gnu-emacs@gnu.org; Mon, 13 Feb 2017 20:43:07 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cdS90-0005P2-OT for bug-gnu-emacs@gnu.org; Mon, 13 Feb 2017 20:43:06 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:40891) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cdS90-0005Oy-Kb for bug-gnu-emacs@gnu.org; Mon, 13 Feb 2017 20:43:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1cdS90-0008OD-CH for bug-gnu-emacs@gnu.org; Mon, 13 Feb 2017 20:43:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: James Bunton Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 14 Feb 2017 01:43:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 25715 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.148703656232219 (code B ref -1); Tue, 14 Feb 2017 01:43:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 14 Feb 2017 01:42:42 +0000 Original-Received: from localhost ([127.0.0.1]:39090 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cdS8f-0008Nb-Jb for submit@debbugs.gnu.org; Mon, 13 Feb 2017 20:42:41 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:59405) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cdRxh-00088Q-4x for submit@debbugs.gnu.org; Mon, 13 Feb 2017 20:31:21 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cdRxa-0002JE-LZ for submit@debbugs.gnu.org; Mon, 13 Feb 2017 20:31:15 -0500 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:36290) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cdRxa-0002J6-HC for submit@debbugs.gnu.org; Mon, 13 Feb 2017 20:31:14 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:50370) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cdRxZ-0008BS-2o for bug-gnu-emacs@gnu.org; Mon, 13 Feb 2017 20:31:14 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cdRxU-0002FZ-HB for bug-gnu-emacs@gnu.org; Mon, 13 Feb 2017 20:31:13 -0500 Original-Received: from out4-smtp.messagingengine.com ([66.111.4.28]:59311) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cdRxU-0002C6-B2 for bug-gnu-emacs@gnu.org; Mon, 13 Feb 2017 20:31:08 -0500 Original-Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailout.nyi.internal (Postfix) with ESMTP id 76DE020AF7 for ; Mon, 13 Feb 2017 20:31:04 -0500 (EST) Original-Received: from web4 ([10.202.2.214]) by compute7.internal (MEProxy); Mon, 13 Feb 2017 20:31:04 -0500 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=content-transfer-encoding:content-type :date:from:message-id:mime-version:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=smtpout; bh=4kmGzR9Spm0nbpY7yqKmJ6XE+ Ps=; b=iax87oqZ2gcFLWWFXGYTVKIN0NT+P6Zkmnr7lKMQXAE5fqDpbLGrOPiqx zHO+0V9JP9gj1fVZHEFKIO9HyD2/bV6s5SEVCU1C3sbEh5rHHu2rWwaITXC2OX26 hfqtMUp41RVIcCfCn8CT/dKKzs8TAadKFyhCr+Vg86IIKegy9s= X-ME-Sender: Original-Received: by mailuser.nyi.internal (Postfix, from userid 99) id 4CBF6BAB4F; Mon, 13 Feb 2017 20:31:04 -0500 (EST) X-Mailer: MessagingEngine.com Webmail Interface - ajax-5653d111 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Mailman-Approved-At: Mon, 13 Feb 2017 20:42:40 -0500 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:129335 Archived-At: I use goto-address-mode, but I want to be able to left-click inside a link without opening it. I've modified the goto-address-highlight-keymap to accomplish this. I can reproduce the problem easily with `emacs -Q`. Put the text below into a buffer and use C-M-x to evalue the two top-level forms. At this point I would expect clicking on the link to set the point and do nothing else. Instead it yanks text into the buffer. I have discovered that adding an extra ignored keybinding for mouse-2 fixes the problem. This confuses me because I'm only ever pressing my left mouse button, mouse-1. This seems like a bug to me :) Thanks for looking! -- James ;; demo text starts here ;; http://example.com (goto-address-mode 1) (setq goto-address-highlight-keymap (let ((m (make-sparse-keymap))) (define-key m (kbd "C-") 'goto-address-at-point) ;; (define-key m (kbd "") 'ignore) ; uncomment this line to workaround the bug (define-key m (kbd "C-c RET") 'goto-address-at-point) m)) ;; demo text ends here