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 configurations Date: Thu, 06 May 2010 10:21:43 +0200 Message-ID: <4BE27C17.3030005@gmx.at> References: <4BB4CF6B.2000007@alice.it> <87vdbhgqgd.fsf@mail.jurta.org> <828BB36311A84C43B96D1F2A559DACAE@us.oracle.com> <87d3xo662u.fsf@mail.jurta.org> <69D40D69CC6F4982A8E91D8D8F0F494F@us.oracle.com> <87r5m4hz39.fsf@mail.jurta.org> <4BD40821.70808@gmx.at> <87zl0rtmqy.fsf@mail.jurta.org> <871vdu6qn5.fsf@mail.jurta.org> <87bpcv1wvt.fsf@mail.jurta.org> <4BE13828.2030609@gmx.at> <87vdb2qo82.fsf@mail.jurta.org> 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: dough.gmane.org 1273159907 11167 80.91.229.12 (6 May 2010 15:31:47 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 6 May 2010 15:31:47 +0000 (UTC) Cc: Ken Hori , Emacs To: Juri Linkov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu May 06 17:31:46 2010 connect(): No such file or directory 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.69) (envelope-from ) id 1OA337-0002ZI-TU for ged-emacs-devel@m.gmane.org; Thu, 06 May 2010 17:31:42 +0200 Original-Received: from localhost ([127.0.0.1]:60687 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OA336-0006zS-PR for ged-emacs-devel@m.gmane.org; Thu, 06 May 2010 11:31:40 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1O9wLD-0002Y9-Sk for emacs-devel@gnu.org; Thu, 06 May 2010 04:21:56 -0400 Original-Received: from [140.186.70.92] (port=37557 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1O9wL7-0002VY-2W for emacs-devel@gnu.org; Thu, 06 May 2010 04:21:54 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1O9wL5-0005X0-H1 for emacs-devel@gnu.org; Thu, 06 May 2010 04:21:48 -0400 Original-Received: from mail.gmx.net ([213.165.64.20]:42437) by eggs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1O9wL5-0005Wo-3O for emacs-devel@gnu.org; Thu, 06 May 2010 04:21:47 -0400 Original-Received: (qmail invoked by alias); 06 May 2010 08:21:45 -0000 Original-Received: from 62-47-62-198.adsl.highway.telekom.at (EHLO [62.47.62.198]) [62.47.62.198] by mail.gmx.net (mp029) with SMTP; 06 May 2010 10:21:45 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX1996UBZjEF9uf1BQFIF5lb1himJy7IdrWf4QucsBF jkFg4xpLvYkGH6 User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) In-Reply-To: <87vdb2qo82.fsf@mail.jurta.org> X-Y-GMX-Trusted: 0 X-detected-operating-system: by eggs.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:124589 Archived-At: > 2. Delete the buffer's window after restoring the saved window configuration. > > Do you see any problem with doing this in `set-window-configuration' > instead of `window-configuration-change-hook'? Since window configurations store coordinates it would have to be done just before the place where `window-configuration-change-hook' is called in `set-window-configuration'. So the effect would be roughly the same. It's not perfect since the windows showing deleted buffers might take up the entire frame. > 3. Delete the buffer's window in the saved window configuration > before restoring it. > > This looks good if it won't break other windows in the same > window configuration. Hardly doable. Note that we might also have to delete internal windows, adjust coordinates or fractions ... > 4. Display some warning message in a temporary buffer in the > restored window. > > This is good too. It keeps the original window configuration unchanged, > and provides information about the deleted buffers. Suitable for user created windows. Not suitable for windows created automatically. What I really want is some sort of function `set-window-configuration' could call whenever it encounters a window with a dead buffer. As a fallback it then would try your (2) first and (4) if the window can't be deleted. martin