From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Nick Roberts Newsgroups: gmane.emacs.devel Subject: Re: Buffer menu fix Date: Tue, 6 Sep 2005 13:16:54 +1200 Message-ID: <17180.60934.359911.605293@farnswood.snap.net.nz> References: <87slwkfxt9.fsf@stupidchicken.com> <17180.56255.712298.670071@farnswood.snap.net.nz> <87br37gi32.fsf@stupidchicken.com> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1125969421 28623 80.91.229.2 (6 Sep 2005 01:17:01 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 6 Sep 2005 01:17:01 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Sep 06 03:16:53 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1ECS4u-0006MS-OL for ged-emacs-devel@m.gmane.org; Tue, 06 Sep 2005 03:16:49 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1ECS9N-0007ND-Lh for ged-emacs-devel@m.gmane.org; Mon, 05 Sep 2005 21:21:25 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1ECS8r-0007FS-JG for emacs-devel@gnu.org; Mon, 05 Sep 2005 21:20:54 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1ECS8o-0007BJ-80 for emacs-devel@gnu.org; Mon, 05 Sep 2005 21:20:51 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1ECS8n-0007AK-Of for emacs-devel@gnu.org; Mon, 05 Sep 2005 21:20:49 -0400 Original-Received: from [202.37.101.8] (helo=viper.snap.net.nz) by monty-python.gnu.org with esmtp (Exim 4.34) id 1ECS6n-0000M2-Cg for emacs-devel@gnu.org; Mon, 05 Sep 2005 21:18:45 -0400 Original-Received: from farnswood.snap.net.nz (p75-tnt1.snap.net.nz [202.124.110.75]) by viper.snap.net.nz (Postfix) with ESMTP id 6604A689D36; Tue, 6 Sep 2005 13:14:43 +1200 (NZST) Original-Received: by farnswood.snap.net.nz (Postfix, from userid 501) id 06DB762A99; Tue, 6 Sep 2005 02:16:54 +0100 (BST) Original-To: Chong Yidong In-Reply-To: <87br37gi32.fsf@stupidchicken.com> X-Mailer: VM 7.19 under Emacs 22.0.50.9 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:42636 Archived-At: Chong Yidong writes: > > With this patch header-line buttons in the buffer list buffer certainly > > respond to Mouse-1 but unfortunately they do this even when > > mouse-1-click-follows-link is nil. > > This behavior is the same as Info-mode. It makes sense because > mouse-1 on the header line would not set point, as it would in the > main editing area. Well it breaks the idiom of mouse-1-click-follows-link. (mouse-1-click-follows-link-except-for-Info-and-Buffer-menu ?). If this is the desired behaviour perhaps a note could be added to the doc for mouse-1-click-follows-link. > > I don't think > > > > > ! (define-key map [follow-link] 'mouse-face) > > > > does anything in this case possibly because map here is a text property and > > not associated with a mode. > > This deals with the case when Buffer-menu-use-header-line is nil. OK, I understand now, perhaps there could be a comment. > > It would be best to omit the line > > > > > ! (define-key map [header-line down-mouse-1] 'ignore) > > > > because then the header line can then respond to mouse-1 clicks and still be > > dragged (try it on the mode-line to see what I mean). > > You can drag it by clicking on any part of the header line outside the > button text. Again, this is the same as Info-mode. In that case I suggest that this is also changed in Info-mode. > > > ! (define-key map "\C-m" > > > ! `(lambda () (interactive) > > > ! (Buffer-menu-sort ,column))) > > > > I don't see the point of this as you can't place point on the header line. > > This deals with the case when Buffer-menu-use-header-line is nil. I see. > > In summary, I don't see how to solve the problem (neither did the original > > author presumably), all I can do is pull your solution apart. > > With my code, clicking mouse-1 actually works, where previously it > didn't. If there are any other problems with my solution, feel free > to point them out. Unlike follow-link, the tooltip shows the mouse-2 binding rather than mouse-1. Nick