mirror of
https://github.com/neovim/neovim.git
synced 2026-07-17 06:31:16 +00:00
vim-patch:9.2.0445: win_fix_scroll() called before win_comp_pos() in command_height() (#39619)
Problem: win_fix_scroll(true) is called before win_comp_pos() in
command_height().
Solution: Move win_fix_scroll(true) after win_comp_pos(), matching the
ordering used in win_drag_status_line() (Jesse Rosenstock).
Patch 9.2.0413 added win_fix_scroll(true) to command_height() to handle
splitkeep when cmdheight changes, but placed the call before win_comp_pos().
win_fix_scroll() reads w_winrow to detect window movement
(620557bd48/src/window.c (L7266)),
but w_winrow is not recomputed until win_comp_pos() runs
(620557bd48/src/window.c (L6516)).
This causes incorrect scroll adjustments and was breaking
Test_smoothscroll_incsearch on macOS CI.
closes: vim/vim#20138
40fc78f0a1
Co-authored-by: Gemini
Co-authored-by: Jesse Rosenstock <jmr@google.com>
This commit is contained in:
@@ -7139,10 +7139,10 @@ void command_height(void)
|
||||
if (p_ch < old_p_ch && command_frame_height && frp != NULL) {
|
||||
frame_add_height(frp, (int)(old_p_ch - p_ch));
|
||||
}
|
||||
win_fix_scroll(true);
|
||||
|
||||
// Recompute window positions.
|
||||
win_comp_pos();
|
||||
win_fix_scroll(true);
|
||||
cmdline_row = Rows - (int)p_ch;
|
||||
redraw_cmdline = true;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user