From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Richard Stallman Newsgroups: gmane.emacs.devel Subject: [matt@mundell.ukfsn.org: Shrinking side-by-side windows] Date: Sun, 08 Feb 2004 10:22:05 -0500 Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: Reply-To: rms@gnu.org NNTP-Posting-Host: deer.gmane.org X-Trace: sea.gmane.org 1076254137 31768 80.91.224.253 (8 Feb 2004 15:28:57 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sun, 8 Feb 2004 15:28:57 +0000 (UTC) Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Sun Feb 08 16:28:50 2004 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1Apqra-0002IZ-00 for ; Sun, 08 Feb 2004 16:28:50 +0100 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1Apqra-0006OC-00 for ; Sun, 08 Feb 2004 16:28:50 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.24) id 1Apqob-0008Iv-KT for emacs-devel@quimby.gnus.org; Sun, 08 Feb 2004 10:25:45 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.24) id 1Apqne-00084c-Up for emacs-devel@gnu.org; Sun, 08 Feb 2004 10:24:46 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.24) id 1Apqn8-0007uS-9o for emacs-devel@gnu.org; Sun, 08 Feb 2004 10:24:45 -0500 Original-Received: from [199.232.76.164] (helo=fencepost.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.24) id 1Apqn7-0007tv-K5 for emacs-devel@gnu.org; Sun, 08 Feb 2004 10:24:13 -0500 Original-Received: from rms by fencepost.gnu.org with local (Exim 4.24) id 1Apql3-0001mk-RW; Sun, 08 Feb 2004 10:22:05 -0500 Original-To: emacs-devel@gnu.org X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.2 Precedence: list List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:19803 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:19803 This looks like a real bug, but I suspect this is not the whole fix. Does someone want to fix this? To: emacs-pretest-bug@gnu.org From: Matthew Mundell Date: 07 Feb 2004 15:21:28 +0000 Subject: Shrinking side-by-side windows Sender: emacs-pretest-bug-bounces+rms=gnu.org@gnu.org With the CVS Emacs, shrink-window-if-larger-than-buffer (C-x -) shrinks a window when there is a window to its right and a single window across the frame above it (or across the bottom of the frame if it is the top-left window). It seems that for a non-top-left window window-safely-shrinkable-p only checks the previous window. And when called without an argument (as by shrink-window-if-larger-than-buffer) window-safely-shrinkable-p treats the top-left window as any other window (checking the previous window instead of only the next). This could be changed follows. =================================================================== RCS file: /cvsroot/emacs/emacs/lisp/window.el,v retrieving revision 1.92 diff -u -r1.92 window.el --- window.el 24 Sep 2003 22:55:42 -0000 1.92 +++ window.el 5 Feb 2004 19:51:43 -0000 @@ -189,10 +189,14 @@ "Non-nil if the WINDOW can be shrunk without shrinking other windows. If WINDOW is nil or omitted, it defaults to the currently selected window." (save-selected-window - (when window (select-window window)) + (if window + (select-window window) + (setq window (selected-window))) (or (and (not (eq window (frame-first-window))) (= (car (window-edges)) - (car (window-edges (previous-window))))) + (car (window-edges (previous-window)))) + (= (car (window-edges)) + (car (window-edges (next-window))))) (= (car (window-edges)) (car (window-edges (next-window))))))) _______________________________________________ Emacs-pretest-bug mailing list Emacs-pretest-bug@gnu.org http://mail.gnu.org/mailman/listinfo/emacs-pretest-bug