mirror of
https://github.com/neovim/neovim.git
synced 2025-09-20 02:08:17 +00:00
cmdheight=0: fix bugs #18961
Continue of #16251 Fix #18953 Fix #18960 Fix #18958 Fix #18955 Fix #18970 Fix #18983 Fix #18995 Fix #19112
This commit is contained in:
@@ -5560,9 +5560,10 @@ static void frame_setheight(frame_T *curfrp, int height)
|
||||
if (curfrp->fr_parent == NULL) {
|
||||
// topframe: can only change the command line
|
||||
if (height > ROWS_AVAIL) {
|
||||
// If height is greater than the available space, try to create space for the frame by
|
||||
// reducing 'cmdheight' if possible, while making sure `cmdheight` doesn't go below 1.
|
||||
height = MIN(ROWS_AVAIL + (p_ch - 1), height);
|
||||
// If height is greater than the available space, try to create space for
|
||||
// the frame by reducing 'cmdheight' if possible, while making sure
|
||||
// `cmdheight` doesn't go below 1.
|
||||
height = MIN((p_ch > 0 ? ROWS_AVAIL + (p_ch - 1) : ROWS_AVAIL), height);
|
||||
}
|
||||
if (height > 0) {
|
||||
frame_new_height(curfrp, height, false, false);
|
||||
|
Reference in New Issue
Block a user