changeset 32695:5a4f1fbd4ed7

(set-window-text-height): Force window-min-height to 1.
author Miles Bader <miles@gnu.org>
date Fri, 20 Oct 2000 16:33:54 +0000
parents 8c9daad87816
children a384f310fd27
files lisp/window.el
diffstat 1 files changed, 6 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/window.el	Fri Oct 20 15:57:00 2000 +0000
+++ b/lisp/window.el	Fri Oct 20 16:33:54 2000 +0000
@@ -351,18 +351,18 @@
 partial-height lines in the text display area.
 
 If WINDOW is nil, the selected window is used.
-If HEIGHT is less than `window-min-height', then WINDOW is deleted.
 
 Note that the current implementation of this function cannot always set
 the height exactly, but attempts to be conservative, by allocating more
 lines than are actually needed in the case where some error may be present."
   (let ((delta (- height (window-text-height window))))
     (unless (zerop delta)
-      (if (and window (not (eq window (selected-window))))
-	  (save-selected-window
-	    (select-window window)
-	    (enlarge-window delta))
-	(enlarge-window delta)))))
+      (let ((window-min-height 1))
+	(if (and window (not (eq window (selected-window))))
+	    (save-selected-window
+	      (select-window window)
+	      (enlarge-window delta))
+	  (enlarge-window delta))))))
 
 
 (defun enlarge-window-horizontally (arg)