From: Yegappan Lakshmanan Date: Sun, 31 May 2026 21:38:30 +0000 (+0000) Subject: patch 9.2.0581: After maximizing and deleting the quickfix buffer, window height... X-Git-Tag: v9.2.0581^0 X-Git-Url: http://git.ipfire.org/gitweb/index.cgi?a=commitdiff_plain;h=07f055f5790cd57b83532928d8e74c1eabe45e5f;p=thirdparty%2Fvim.git patch 9.2.0581: After maximizing and deleting the quickfix buffer, window height is wrong Problem: After maximizing and deleting the quickfix buffer, window height is wrong (tertium) Solution: Reset the winfixheight option when a quickfix buffer is deleted from a window (Yegappan Lakshmanan) fixes: #3378 closes: #20403 Signed-off-by: Yegappan Lakshmanan Signed-off-by: Christian Brabandt --- diff --git a/src/buffer.c b/src/buffer.c index 07176fbc43..d287183293 100644 --- a/src/buffer.c +++ b/src/buffer.c @@ -736,6 +736,11 @@ aucmd_abort: unblock_autocmds(); } + // When a quickfix buffer is deleted from a window, clear the + // 'winfixheight' option. + if (bt_quickfix(buf) && win_valid && win->w_buffer == buf) + win->w_p_wfh = FALSE; + // Remember if the buffer may be hidden soon, or is already hidden. hiding_buf = buf->b_nwindows <= 0 || ((win_valid || closed_popup) && win->w_buffer == buf && buf->b_nwindows == 1); diff --git a/src/testdir/test_quickfix.vim b/src/testdir/test_quickfix.vim index c656d205f0..b0c4475ccd 100644 --- a/src/testdir/test_quickfix.vim +++ b/src/testdir/test_quickfix.vim @@ -7090,4 +7090,20 @@ func Test_set_qftf_in_sandbox() call Xtest_set_qftf_in_sandbox('l') endfunc +" Test for the 'statusline' height remaining at one when the quickfix buffer +" is wiped out when quickfix window is the only window open. +func Test_qf_statusline_height() + %bw! + copen + wincmd p + let prev_wh = winheight('.') + wincmd p + only + bw! + copen + wincmd p + call assert_equal(prev_wh, winheight('.')) + %bw! +endfunc + " vim: shiftwidth=2 sts=2 expandtab diff --git a/src/version.c b/src/version.c index e39f67aad7..44bc20abdc 100644 --- a/src/version.c +++ b/src/version.c @@ -729,6 +729,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 581, /**/ 580, /**/