From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: martin rudalics Newsgroups: gmane.emacs.devel Subject: Re: mouse-autoselect-window raises frames Date: Thu, 11 Oct 2007 20:15:11 +0200 Message-ID: <470E682F.7090007@gmx.at> References: <470D3993.8040003@gmx.at> <470DE3B2.7010109@gmx.at> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1192126611 31164 80.91.229.12 (11 Oct 2007 18:16:51 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 11 Oct 2007 18:16:51 +0000 (UTC) Cc: emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Oct 11 20:16:50 2007 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 1Ig2aR-0007FW-Mt for ged-emacs-devel@m.gmane.org; Thu, 11 Oct 2007 20:16:44 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Ig2aL-0002cU-UV for ged-emacs-devel@m.gmane.org; Thu, 11 Oct 2007 14:16:37 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Ig2Zt-0002Xu-SK for emacs-devel@gnu.org; Thu, 11 Oct 2007 14:16:09 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Ig2Zs-0002XI-6a for emacs-devel@gnu.org; Thu, 11 Oct 2007 14:16:09 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Ig2Zs-0002XB-2K for emacs-devel@gnu.org; Thu, 11 Oct 2007 14:16:08 -0400 Original-Received: from mail.gmx.net ([213.165.64.20]) by monty-python.gnu.org with smtp (Exim 4.60) (envelope-from ) id 1Ig2Zr-0005NZ-Is for emacs-devel@gnu.org; Thu, 11 Oct 2007 14:16:07 -0400 Original-Received: (qmail invoked by alias); 11 Oct 2007 18:16:03 -0000 Original-Received: from N728P022.adsl.highway.telekom.at (EHLO [62.47.34.246]) [62.47.34.246] by mail.gmx.net (mp019) with SMTP; 11 Oct 2007 20:16:03 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX18z2SBI3qkz8WMJQdNMowFMf3FIWKYBQvcqpSbvks 6RgDYmfenVTkqU User-Agent: Mozilla Thunderbird 1.0 (Windows/20041206) X-Accept-Language: de-DE, de, en-us, en In-Reply-To: X-Y-GMX-Trusted: 0 X-detected-kernel: by monty-python.gnu.org: Linux 2.6, seldom 2.4 (older, 4) 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:80647 Archived-At: > The way I've usually heard "embarrassing" used, is to mean "something of > which you're ashamed". I guess you use it here more like "annoying"? Yes (although you were probably ashamed of the way Emacs behaves due to my changes). >>(note that `x-focus-frame' is not available on Windows installs) > > > Are you saying that under w32, you used select-frame + raise-frame (the > only thing select-frame-set-input-focus does in this case) as a substitute > for x-focus-frame? Emacs 22 uses `w32-focus-frame' but I think Jason has changed that for Emacs 23. The doc-string is w32-focus-frame is a built-in function in `src/w32fns.c'. (w32-focus-frame frame) Give frame input focus, raising to foreground if necessary. Hence, the Windows substitute for `x-focus-frame' and `select-frame-set-input-focus' both raise the frame. > I do want mouse autoselection. And changing focus-follows-mouse has no > effect w.r.t this problem. `focus-follows-mouse' nil should inhibit selecting and subsequently raising another frame. If it doesn't it's a bug. > The problem is very simple: select-window events > (currently) are only generated by mouse movement and Emacs should *never* > call raise-frame in response to a mouse-movement (except when asked very > specifically, such as when the frame is marked auto-raise). The problem is that mouse movement also generates a switch-frame event which is equally disturbing. But I'm already convinced that there's no reason to either focus or raise the frame in `handle-select-window'. > If the window-manager wants to raise the window in order to give it focus, > that's "OK" (it would piss me off, but that's why I don't use such a window > manager). But it's not OK for Emacs to do that. An auto-raise window-manager doesn't raise the window in order to give it focus but simply in order to avoid changing the position of `point' (as you would do with a mouse click) when you want to switch to a specific window with the mouse.