# HG changeset patch # User Stefan Monnier # Date 1151850772 0 # Node ID 695dbebf4c20cf6a20ff9cbb4cf122dfbddef291 # Parent 31835ba46d29c2a9ed1fdb2c252b14f5211d2397 (set-window-text-height): Only set window-min-height to 1 if that's the requested size. diff -r 31835ba46d29 -r 695dbebf4c20 lisp/window.el --- a/lisp/window.el Sun Jul 02 14:29:28 2006 +0000 +++ b/lisp/window.el Sun Jul 02 14:32:52 2006 +0000 @@ -532,7 +532,11 @@ lines than are actually needed in the case where some error may be present." (let ((delta (- height (window-text-height window)))) (unless (zerop delta) - (let ((window-min-height 1)) + ;; Setting window-min-height to a value like 1 can lead to very + ;; bizarre displays because it also allows Emacs to make *other* + ;; windows 1-line tall, which means that there's no more space for + ;; the modeline. + (let ((window-min-height (min 2 height))) ;One text line plus a modeline. (if (and window (not (eq window (selected-window)))) (save-selected-window (select-window window)