]> granicus.if.org Git - vim/commitdiff
patch 9.0.0187: command line height changes when maximizing window height v9.0.0187
authorBram Moolenaar <Bram@vim.org>
Wed, 10 Aug 2022 16:23:12 +0000 (17:23 +0100)
committerBram Moolenaar <Bram@vim.org>
Wed, 10 Aug 2022 16:23:12 +0000 (17:23 +0100)
Problem:    Command line height changes when maximizing window height.
Solution:   Do not change the command line height. (closes #10885)

src/testdir/test_window_cmd.vim
src/version.c
src/window.c

index cfa5b63cf9ebb1d5838f190b6e1ae988df498e43..e761c21c3af0391d10b76cb9757bd814a380effa 100644 (file)
@@ -38,6 +38,26 @@ func Test_window_cmd_cmdwin_with_vsp()
   set ls&vim
 endfunc
 
+func Test_cmdheight_not_changed()
+  set cmdheight=2
+  set winminheight=0
+  augroup Maximize
+    autocmd WinEnter * wincmd _
+  augroup END
+  split
+  tabnew
+  tabfirst
+  call assert_equal(2, &cmdheight)
+
+  tabonly!
+  only
+  set winminwidth& cmdheight&
+  augroup Maximize
+    au!
+  augroup END
+  augroup! Maximize
+endfunc
+
 " Test for jumping to windows
 func Test_window_jump()
   new
index 6e278e5fac357c524b63ba82dca7c77cbfb8444b..1e326b31ee3ce1e0ead3124e80de3ed8e89bd4f4 100644 (file)
@@ -735,6 +735,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    187,
 /**/
     186,
 /**/
index f0d66da2ff4ac89a101e615dc0b0517cd2d506ff..2c7bd8edb7151a9a2b40306c2e74b999f963ca8e 100644 (file)
@@ -5666,8 +5666,6 @@ win_setheight_win(int height, win_T *win)
     if (full_screen && msg_scrolled == 0 && row < cmdline_row)
        screen_fill(row, cmdline_row, 0, (int)Columns, ' ', ' ', 0);
     cmdline_row = row;
-    p_ch = MAX(Rows - cmdline_row, 0);
-    curtab->tp_ch_used = p_ch;
     msg_row = row;
     msg_col = 0;