patch 9.0.0670: no space for command line when there is a tabline
Problem: No space for command line when there is a tabline.
Solution: Correct computation of where the command line should be.
(closes #11295)
diff --git a/src/window.c b/src/window.c
index 1f3f9ad..f63b856 100644
--- a/src/window.c
+++ b/src/window.c
@@ -4332,7 +4332,7 @@
// When cmdheight is changed in a tab page with '<C-w>-', cmdline_row is
// changed but p_ch and tp_ch_used are not changed. Thus we also need to
// check cmdline_row.
- if ((row < cmdline_row) && (cmdline_row <= Rows - p_ch))
+ if (row < cmdline_row && cmdline_row <= Rows - p_ch)
clear_cmdline = TRUE;
// The tabpage line may have appeared or disappeared, may need to resize
@@ -6665,7 +6665,7 @@
return;
// Update cmdline_row to what it should be: just below the last window.
- cmdline_row = topframe->fr_height;
+ cmdline_row = topframe->fr_height + tabline_height();
// If cmdline_row is smaller than what it is supposed to be for 'cmdheight'
// then set old_p_ch to what it would be, so that the windows get resized