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: Coordinates and Windows Date: Sat, 18 Jul 2015 11:03:29 +0200 Message-ID: <55AA1661.1090106@gmx.at> References: <55A60508.7090903@gmx.at> <83oajd79kz.fsf@gnu.org> <55A6A4A1.1030307@gmx.at> <83fv4p6wqp.fsf@gnu.org> <55A759D1.5090001@gmx.at> <83bnfc6um1.fsf@gnu.org> <55A7F68A.3040003@gmx.at> <83y4if53s8.fsf@gnu.org> <55A904C8.2070106@gmx.at> <83wpxy6f0x.fsf@gnu.org> <55A94234.7070600@gmx.at> <83twt264g0.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1437210245 23761 80.91.229.3 (18 Jul 2015 09:04:05 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 18 Jul 2015 09:04:05 +0000 (UTC) Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Jul 18 11:03:56 2015 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ZGO2F-0001H0-QY for ged-emacs-devel@m.gmane.org; Sat, 18 Jul 2015 11:03:55 +0200 Original-Received: from localhost ([::1]:47534 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZGO2E-0006zz-Uj for ged-emacs-devel@m.gmane.org; Sat, 18 Jul 2015 05:03:54 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:34159) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZGO22-0006ze-2z for emacs-devel@gnu.org; Sat, 18 Jul 2015 05:03:43 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZGO1y-0006Bv-T7 for emacs-devel@gnu.org; Sat, 18 Jul 2015 05:03:42 -0400 Original-Received: from mout.gmx.net ([212.227.15.15]:58652) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZGO1y-0006Br-Iq; Sat, 18 Jul 2015 05:03:38 -0400 Original-Received: from [88.117.85.91] ([88.117.85.91]) by mail.gmx.com (mrgmx002) with ESMTPSA (Nemesis) id 0MCtql-1Z7LTO2ihP-009kIi; Sat, 18 Jul 2015 11:03:37 +0200 In-Reply-To: <83twt264g0.fsf@gnu.org> X-Provags-ID: V03:K0:i/pglvVf+kn9RPfiQHoIpeh2yNw1uOR9hGrEJBHaaV2pTr/Q1IV foJeZaYFiJRcj/2/+ZB4NbnzS//c06C+zzA1bVOJTc8LvkuMny55KA3DEsCAP1Zke458q27 l1eTf8QoJFVG7D066B7xYzf0C6BGubNxPnAz/Y7g0D/KK/fT81ERT5jJIzADp0ylFh1PN39 53dGcjSFXt40w6/Gyv4yA== X-UI-Out-Filterresults: notjunk:1;V01:K0:zLKNfqA2XCk=:Lrl2LLgjejaLaUT30NIQHi 3n38Cl46mItkNlJpTch2ZE4clGqK/5EvnzvnK1ftsU/vSNMsaTZ6D2WO/jU8NLoVNnK84rDTP 3XvzwqaqoL88NcMu9LS3MsssLMWZEy5fsYLFmkWsAHsLoRZg3GoSw+vmZF10nNTwhn1evAOeP OHka5FlfvXzePfOFDrKT0rWLK6cd0alOnnvgUPLr5KgSUb71UkC9++3rWIZjA68IhnxbiXzOp kt01Jhb/zIzG4DyedoTxceWX7Ri8Qok6z4QJMuavdN+M8m6exK/dH/RWRnlLNtvCwE4YTiKqz DGza682Yrk4kLT1BH2NIm2R8zLuFaSfk4x0+1dVc7+v1WsNQbFdRnDX9p6r4F2vkZYQ5s8Gvt hr4WTExi7qdLDyODqQo6I2qSCucxHLmwwjosdikYMgg7th3u0FldwRCcPTHnUDcMqpGB5ixXB a+ze56v1SCMMVYJ2QUTOXJUFym0JHucDzMhpg3TKFRE1eAZphvPp5uE6GQzR3c+J7mpzbsd3o JVJklu3ui5je3Espngf+JDm5unyLEV9VuPps5UsB/cjISWHvWdioku0JN7SoKzI32G7St7bs3 EsV1TrzqHg5KMEFmn+NVhSceIHNB7Ub2n7Qcpk0zNQa9KOPaKx6DZAJVezIN+hTNMYKhD9UWk bEYpJk0rPdP9GFi8ETaU1alHlTyezwRPAYjJacmCnn61uD0snVZwBo3i2qEL0gb6iBgA= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] X-Received-From: 212.227.15.15 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:187944 Archived-At: >> For example, on Windows I need accurate dimensions of decorations to >> emulate fullheight and fullwidth fullscreen modes. > > What do you mean by "emulate"? AFAIK, these are supported on Windows > without any need for emulation. The Windows API knows only minimized and maximized frames. The fullboth, fullheight and fullwidth ones must be emulated. I read that Aero Snap provides a similar service but to my knowledge we can't call that from within Emacs. Also there was a bug report (by Juanma IIRC) that we don't support some Snap feature(s) yet. Just to explain what emulation means in this context: When a user sets the `fullscreen' parameter to `maximized' we send a maximize request to the OS, the latter calculates the coordinates and calls us back with the new coordiantes. When a user sets the `fullscreen' parameter to `fullheight', Emacs calculates the new coordinates and sends a resize request to the OS. The OS has no idea that our frame is "full height". > Why do you need _frame_ relative coordinates to display something at > _window_ relative position? Because currently `window-absolute-pixel-edges' is not accurate. I use a three steps translation process: (1) `pos-visible-in-window-p' gets me "pixel coordinates relative to the top left corner of the window". (2) I add the offsets of the window within its frame. (3) I add the offsets of the frame on the display. But the frame offsets I get via the `left' and `top' frame parameters in (3) are those of the "outer frame" as placed by the window manager. Hence in (2) the offsets provided, for example, by `window-pixel-edges' as "relative to 0, 0 at the top left corner of the frame" are insufficient because that corner is not the one from (3). >> No. The root window is beneath the tool bar window separated from the >> latter by the internal border. > > Strange. In a session where you never split windows, the root window is always the one you see and work in. Also, the minibuffer window, if it exists, is beneath the root window unless your frame is a "minibuffer-only" one. martin