aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/option.c
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2022-10-06 09:03:49 +0800
committerGitHub <noreply@github.com>2022-10-06 09:03:49 +0800
commitbc64aa435b84bb3a43501e101c51507c75fbd349 (patch)
treebb75d9fed367173cd77bcbf6ccc8206a9c476f95 /src/nvim/option.c
parent6ae4a6e0711035a8a0801dd6fdb545e020bccd70 (diff)
downloadrneovim-bc64aa435b84bb3a43501e101c51507c75fbd349.tar.gz
rneovim-bc64aa435b84bb3a43501e101c51507c75fbd349.tar.bz2
rneovim-bc64aa435b84bb3a43501e101c51507c75fbd349.zip
vim-patch:9.0.0665: setting 'cmdheight' has no effect if last window was resized (#20500)
Problem: Setting 'cmdheight' has no effect if last window was resized. Solution: Do apply 'cmdheight' when told to. Use the frame height instead of the cmdline_row. (closes vim/vim#11286) https://github.com/vim/vim/commit/0816f473ab2f6cf7d8311c0f97371cada7f20d18
Diffstat (limited to 'src/nvim/option.c')
-rw-r--r--src/nvim/option.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/nvim/option.c b/src/nvim/option.c
index 4a93fddc1b..a2dd2e7d84 100644
--- a/src/nvim/option.c
+++ b/src/nvim/option.c
@@ -2468,7 +2468,7 @@ static char *set_num_option(int opt_idx, char_u *varp, long value, char *errbuf,
// if p_ch changed value, change the command line height
// Only compute the new window layout when startup has been
// completed. Otherwise the frame sizes may be wrong.
- if (p_ch != old_value && full_screen) {
+ if ((p_ch != old_value || topframe->fr_height != Rows - p_ch) && full_screen) {
command_height();
}
} else if (pp == &p_uc) {