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, 29 Jul 2009 11:05:27 +0200 Message-ID: <4A7010D7.3050305@gmx.at> References: <4A6DAD94.8040006@gmx.at> <4A6DAF71.6070002@gmx.at> <4A6DBB3A.90001@gmx.at> <4A6DC1A1.2000208@gmx.at> <4A6DDB61.8090403@gmx.at> <4A6EAB02.6080701@gmx.at> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1248859013 14658 80.91.229.12 (29 Jul 2009 09:16:53 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 29 Jul 2009 09:16:53 +0000 (UTC) Cc: emacs-devel@gnu.org, Lennart Borgman , Miles Bader To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Jul 29 11:16:45 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 1MW5H7-0005mN-Qi for ged-emacs-devel@m.gmane.org; Wed, 29 Jul 2009 11:16:42 +0200 Original-Received: from localhost ([127.0.0.1]:41524 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MW5H6-0005kO-QS for ged-emacs-devel@m.gmane.org; Wed, 29 Jul 2009 05:16:40 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MW5Cv-0003jr-DB for emacs-devel@gnu.org; Wed, 29 Jul 2009 05:12:21 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MW5Cn-0003dp-1J for emacs-devel@gnu.org; Wed, 29 Jul 2009 05:12:17 -0400 Original-Received: from [199.232.76.173] (port=60679 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MW5Cm-0003de-RC for emacs-devel@gnu.org; Wed, 29 Jul 2009 05:12:12 -0400 Original-Received: from mail.gmx.net ([213.165.64.20]:38841) by monty-python.gnu.org with smtp (Exim 4.60) (envelope-from ) id 1MW5Cm-0007ym-0V for emacs-devel@gnu.org; Wed, 29 Jul 2009 05:12:12 -0400 Original-Received: (qmail invoked by alias); 29 Jul 2009 09:05:29 -0000 Original-Received: from 62-47-35-212.adsl.highway.telekom.at (EHLO [62.47.35.212]) [62.47.35.212] by mail.gmx.net (mp066) with SMTP; 29 Jul 2009 11:05:29 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX1+UHvV6TG2UTo3NhAaa26GYDpDD1ZUpYa7HiAzb6O vA0Yacn/+Zq2ST User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) In-Reply-To: X-Y-GMX-Trusted: 0 X-FuHaFi: 0.77 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:113332 Archived-At: > I'm talking about something else: after having a found a solution > (i.e. you know exactly the size you want for of each window and it is > correct for the size of the frame), find a set of calls to > enlarge/shrink-window (or equivalent) that will bring you from the > current window configuration to the desired window configuration. Indeed. Specifying a good interface for that seems tedious. Something like a function which accepts a list of all windows and their new sizes, checks whether the sizes add up correctly, and applies them. > But yes, "finding a solution" is itself a difficult problem. NP-complete, I suppose. I always wondered whether there are configurations where your code could produce a suboptimal solution by stopping to early. martin