From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: [simon.marshall@bogus.example.com: mouse-autoselect-window ne eds a delay] Date: Tue, 04 Jul 2006 12:15:55 -0400 Message-ID: References: <81CCA6588E60BB42BE68BD029ED4826007B77E4E@wimex2.wim.midas-kapiti.com> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1152029805 7515 80.91.229.2 (4 Jul 2006 16:16:45 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 4 Jul 2006 16:16:45 +0000 (UTC) Cc: "'bob@rattlesnake.com'" , "'Emacs Developers \(emacs-devel@gnu.org\)'" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Jul 04 18:16:41 2006 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1FxnZe-0005dV-5M for ged-emacs-devel@m.gmane.org; Tue, 04 Jul 2006 18:16:30 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FxnZd-00058n-G7 for ged-emacs-devel@m.gmane.org; Tue, 04 Jul 2006 12:16:29 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1FxnZF-00053F-IT for emacs-devel@gnu.org; Tue, 04 Jul 2006 12:16:05 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1FxnZD-00052V-R6 for emacs-devel@gnu.org; Tue, 04 Jul 2006 12:16:05 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FxnZD-00052P-Iz for emacs-devel@gnu.org; Tue, 04 Jul 2006 12:16:03 -0400 Original-Received: from [132.204.24.67] (helo=mercure.iro.umontreal.ca) by monty-python.gnu.org with esmtp (Exim 4.52) id 1Fxnmv-0003JH-E2 for emacs-devel@gnu.org; Tue, 04 Jul 2006 12:30:13 -0400 Original-Received: from hidalgo.iro.umontreal.ca (hidalgo.iro.umontreal.ca [132.204.27.50]) by mercure.iro.umontreal.ca (Postfix) with ESMTP id EC9EA2CF4E4; Tue, 4 Jul 2006 12:16:02 -0400 (EDT) Original-Received: from faina.iro.umontreal.ca (faina.iro.umontreal.ca [132.204.26.177]) by hidalgo.iro.umontreal.ca (Postfix) with ESMTP id A4CDF445C; Tue, 4 Jul 2006 12:15:55 -0400 (EDT) Original-Received: by faina.iro.umontreal.ca (Postfix, from userid 20848) id 955D36C8DB; Tue, 4 Jul 2006 12:15:55 -0400 (EDT) Original-To: "Marshall, Simon" In-Reply-To: <81CCA6588E60BB42BE68BD029ED4826007B77E4E@wimex2.wim.midas-kapiti.com> (Simon Marshall's message of "Wed, 28 Jun 2006 10:11:09 +0100") User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) X-DIRO-MailScanner-Information: Please contact the ISP for more information X-DIRO-MailScanner: Found to be clean X-DIRO-MailScanner-SpamCheck: n'est pas un polluriel, SpamAssassin (score=-2.82, requis 5, autolearn=not spam, ALL_TRUSTED -2.82) X-DIRO-MailScanner-From: monnier@iro.umontreal.ca 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:56501 Archived-At: > OTOH, I use the menu bar if (a) I happen to be holding the mouse, (b) I > can't remember the key binding, or (c) there isn't a key binding. My report > was pointing out a problem with mouse-autoselect-window when used with split > windows and the menu or tool bar. Given that you don't use the menu or tool > bar, ... I agree with you that it's a problem. The same problem appears on Mac OS X if you want to use focus-follows-mouse because Mac OS X's window system uses a single menu-bar shared between all applications. I don't know how they solve it, but I know how X11 and w32 solve it: have each frame carry its own menu-bar. And that's indeed what I do here: I use C-down-mouse-3 to get the menu-bar at point rather than having to move the mouse to the top of the frame. Now, I agree that it only provides a workaround rather than a fix, but some people (e.g. myself) may prefer this workaround rather than the delayed-selection you propose. BTW, I believe that you can implement a form of delayed-selection without any of the heavy hacking mentioned in this thread. Basically: change `handle-select-window' such that it doesn't immediately selects the window but instead fires a timer (and kills any still pending delayed-selection timer). Additionally to the timer, it could add a pre-command-hook so that hitting a key forces the selection to be done immediately. All in elisp. Stefan