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: moving window handling into lisp Date: Wed, 12 Aug 2009 10:57:19 +0200 Message-ID: <4A8283EF.5080007@gmx.at> References: <4A6DDB61.8090403@gmx.at> <4A6EAB02.6080701@gmx.at> <4A7010D7.3050305@gmx.at> <4A81374E.9050401@gmx.at> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1250067615 10712 80.91.229.12 (12 Aug 2009 09:00:15 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 12 Aug 2009 09:00:15 +0000 (UTC) Cc: Stefan Monnier , emacs-devel@gnu.org To: Lennart Borgman Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Aug 12 11:00:07 2009 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 1Mb9gi-00013G-Oj for ged-emacs-devel@m.gmane.org; Wed, 12 Aug 2009 11:00:06 +0200 Original-Received: from localhost ([127.0.0.1]:37736 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mb9gg-00041n-PT for ged-emacs-devel@m.gmane.org; Wed, 12 Aug 2009 05:00:02 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Mb9eC-00034b-Fg for emacs-devel@gnu.org; Wed, 12 Aug 2009 04:57:28 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Mb9e7-00032n-Qd for emacs-devel@gnu.org; Wed, 12 Aug 2009 04:57:28 -0400 Original-Received: from [199.232.76.173] (port=52983 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mb9e7-00032g-Jr for emacs-devel@gnu.org; Wed, 12 Aug 2009 04:57:23 -0400 Original-Received: from mail.gmx.net ([213.165.64.20]:51529) by monty-python.gnu.org with smtp (Exim 4.60) (envelope-from ) id 1Mb9e6-0004e9-Kk for emacs-devel@gnu.org; Wed, 12 Aug 2009 04:57:23 -0400 Original-Received: (qmail invoked by alias); 12 Aug 2009 08:57:21 -0000 Original-Received: from 62-47-48-137.adsl.highway.telekom.at (EHLO [62.47.48.137]) [62.47.48.137] by mail.gmx.net (mp068) with SMTP; 12 Aug 2009 10:57:21 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX1/dFr0yRG3dGqkIFeMEmuh5dPUMloTI+aQgBk4UaV K9VSKyL2Q3lqFK User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) In-Reply-To: X-Y-GMX-Trusted: 0 X-FuHaFi: 0.72 X-detected-operating-system: by monty-python.gnu.org: Genre and OS details not recognized. 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:114133 Archived-At: > 1) Make a logical representation of the window tree where you split as > necessary. > 2) Walk this logical tree bottom up collecting minimum required window sizes. > 3) Walk top bottom-wise applying the sizes as they could be. > 4) Apply the splitting and the computed sizes to the window tree. > > Step 3 could of course fail if the minimum sizes does not fit. The case where the minimum (and probably fixed) sizes don't fit is what makes this problem hard and is _all_ I care about. You end up by deleting a window because it drops below some minimum height and when that windows is missing you can't keep the fixed-sizeness of another window ... > Step 4 should be know problem in itself (fi the needed primitives are > available of course). The current primitives do a lot of deleting by themselves. So your tree carefully laid out in 3) might become a mess in 4). martin