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: window-normal-size Date: Sun, 15 Jul 2012 15:00:19 +0200 Message-ID: <5002BEE3.5000309@gmx.at> References: <500258D0.8030208@yandex.ru> 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: dough.gmane.org 1342357232 16115 80.91.229.3 (15 Jul 2012 13:00:32 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sun, 15 Jul 2012 13:00:32 +0000 (UTC) Cc: Emacs development discussions To: Dmitry Antipov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Jul 15 15:00:32 2012 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 1SqOR5-0003XV-Q6 for ged-emacs-devel@m.gmane.org; Sun, 15 Jul 2012 15:00:31 +0200 Original-Received: from localhost ([::1]:57773 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SqOR5-00078h-4U for ged-emacs-devel@m.gmane.org; Sun, 15 Jul 2012 09:00:31 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:45318) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SqOR2-00078c-Sb for emacs-devel@gnu.org; Sun, 15 Jul 2012 09:00:29 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SqOR1-0002g7-UD for emacs-devel@gnu.org; Sun, 15 Jul 2012 09:00:28 -0400 Original-Received: from mailout-de.gmx.net ([213.165.64.22]:44856) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1SqOR1-0002d4-Jn for emacs-devel@gnu.org; Sun, 15 Jul 2012 09:00:27 -0400 Original-Received: (qmail invoked by alias); 15 Jul 2012 13:00:25 -0000 Original-Received: from 62-47-62-104.adsl.highway.telekom.at (EHLO [62.47.62.104]) [62.47.62.104] by mail.gmx.net (mp032) with SMTP; 15 Jul 2012 15:00:25 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX1/tGMUInD7t9PMig92dG+jBwhFiSaEwMnqmkWFYjE 1abEJfSpZyoII9 In-Reply-To: <500258D0.8030208@yandex.ru> X-Y-GMX-Trusted: 0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 213.165.64.22 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:151621 Archived-At: > If frame has the minibuffer window, I suppose you mean a "normal" frame with a live root window and a minibuffer window. > should > > (window-normal-size) > > be always equal to > > (/ (float (window-total-height)) (float (- (frame-height) > (window-total-height (minibuffer-window)))))? I can't tell because I don't know what `frame-height' is supposed to return. > If not, why these values are slightly different? The normalized size of a window is independent from the size of its frame. Conceptually, the sum of the normal sizes of the child windows of any window is 1.0. A frame root window doesn't have a parent window, it's normalized size is by definition 1.0. For any other window, its normalized size is roughly spoken the fraction corresponding to the size the window should have wrt to its parent window if the frame were sufficiently large so that all its windows would have their ideal size (that is, the size the user asked for when the window was created or explicitly resized). Note that the normalized size does _not_ change when the window's parent or its frame is resized. martin