aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/nvim/screen.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/nvim/screen.c b/src/nvim/screen.c
index 1e20b77c5c..384636f705 100644
--- a/src/nvim/screen.c
+++ b/src/nvim/screen.c
@@ -7507,6 +7507,10 @@ void screen_resize(int width, int height)
Rows = height;
Columns = width;
check_shellsize();
+ int max_p_ch = Rows - min_rows() + 1;
+ if (!ui_has(kUIMessages) && p_ch > max_p_ch) {
+ p_ch = max_p_ch ? max_p_ch : 1;
+ }
height = Rows;
width = Columns;
p_lines = Rows;