From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Katsumi Yamaoka Newsgroups: gmane.emacs.devel,gmane.emacs.gnus.general Subject: mouse-1 click on widget button Date: Mon, 21 Jan 2008 20:12:21 +0900 Organization: Emacsen advocacy group Message-ID: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1200913995 6514 80.91.229.12 (21 Jan 2008 11:13:15 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 21 Jan 2008 11:13:15 +0000 (UTC) Cc: ding@gnus.org To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Jan 21 12:13:34 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1JGuan-0001J2-K4 for ged-emacs-devel@m.gmane.org; Mon, 21 Jan 2008 12:13:29 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JGuaN-0000At-Cv for ged-emacs-devel@m.gmane.org; Mon, 21 Jan 2008 06:13:03 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JGuZw-0008HD-OR for emacs-devel@gnu.org; Mon, 21 Jan 2008 06:12:36 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JGuZv-0008Fv-F8 for emacs-devel@gnu.org; Mon, 21 Jan 2008 06:12:35 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JGuZv-0008Fa-7i for emacs-devel@gnu.org; Mon, 21 Jan 2008 06:12:35 -0500 Original-Received: from orlando.hostforweb.net ([216.246.45.90]) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1JGuZu-0003yh-Sd for emacs-devel@gnu.org; Mon, 21 Jan 2008 06:12:35 -0500 Original-Received: from [66.225.201.151] (port=43789 helo=mail.jpl.org) by orlando.hostforweb.net with esmtpa (Exim 4.68) (envelope-from ) id 1JGuZn-0000EU-H6; Mon, 21 Jan 2008 05:12:28 -0600 X-Hashcash: 1:20:080121:emacs-devel@gnu.org::MJCUdr4xxr+hasUj:0000000000000000000000000000000000000000000hcX X-Hashcash: 1:20:080121:ding@gnus.org::okx6SANZT3hNkG+L:00001Xnf X-Face: #kKnN,xUnmKia.'[pp`; Omh}odZK)?7wQSl"4o04=EixTF+V[""w~iNbM9ZL+.b*_CxUmFk B#Fu[*?MZZH@IkN:!"\w%I_zt>[$nm7nQosZ<3eu; B:$Q_:p!',P.c0-_Cy[dz4oIpw0ESA^D*1Lw= L&i*6&( User-Agent: Gnus/5.110007 (No Gnus v0.7) Emacs/23.0.50 (gnu/linux) Cancel-Lock: sha1:U068KFyEPfdUVszMWh+NfeAmWmY= X-Antivirus-Scanner: Clean mail though you should still use an Antivirus X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - orlando.hostforweb.net X-AntiAbuse: Original Domain - gnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - jpl.org X-Source: X-Source-Args: X-Source-Dir: X-detected-kernel: by monty-python.gnu.org: Genre and OS details not recognized. X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:87207 gmane.emacs.gnus.general:66185 Archived-At: Hi, I use this: (setq mouse-1-click-follows-link nil mouse-1-click-in-non-selected-windows nil) Even so, mouse-1 click on a url string in the Gnus article buffer raises the web browser. It is because Gnus puts a widget button on a text which looks like a url[1], and the button is sensitive to mouse-1 as well as mouse-2 because of the default value of `widget-keymap'[2] defined in wid-edit.el as follows: (defvar widget-keymap [...] (define-key map [down-mouse-2] 'widget-button-click) (define-key map [down-mouse-1] 'widget-button-click) The changelog relevant to this is: 2006-02-14 Chong Yidong * wid-edit.el (widget-keymap): Bind down-mouse-1 to widget-button-click. * cus-edit.el (custom-mode-map): Remove mouse-1 binding. (custom-mode): Update docstring. * cus-theme.el (custom-new-theme-mode-map): Remove mouse-1 binding. It annoyed me since I usually click mouse-1 on an Emacs frame in order to move the point, to select the frame, to copy text, etc. When I click a url string accidentally, the web browser launches regardless of my will. I was often vexed by this and now I have: (eval-after-load "wid-edit" '(define-key widget-keymap [down-mouse-1] nil)) Because of the default value of `mouse-1-click-follows-link', mouse-1 click behaves like moude-2 now even if there is no mouse-1 binding in `widget-keymap'. Why don't we remove it from `widget-keymap'? Regards, [1] `gnus-article-add-buttons' adds a widget button if `gnus-treat-buttonize' is non-nil (the default). [2] `gnus-article-mode-map' is set so that its parent is `widget-keymap'.