diff options
| author | zeertzjq <zeertzjq@outlook.com> | 2026-08-04 07:43:09 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-08-03 23:43:09 +0000 |
| commit | 21a0227d2f654ddc568c3733e72150021cd84a6b (patch) | |
| tree | 8eb712be2387f1b564856f3c40c4bdb34b2b739a /runtime/plugin/python_setup.vim | |
| parent | 794886aae73c80738db6a07cc8ebc657ca356384 (diff) | |
| download | rneovim-21a0227d2f654ddc568c3733e72150021cd84a6b.tar.gz rneovim-21a0227d2f654ddc568c3733e72150021cd84a6b.tar.bz2 rneovim-21a0227d2f654ddc568c3733e72150021cd84a6b.zip | |
vim-patch:9.2.0904: "zb" scrolls incorrectly with cursor just above fold (#41143)
Problem: "zb" scrolls incorrectly with cursor just above fold.
Solution: Handle boff.lnum being set to the last line of a fold
(zeertzjq).
With the cursor just above fold, botline_forw() moves boff.lnum to the
last line of the fold, but curwin->w_botline is at the first line of the
fold, so the boff.lnum == curwin->w_botline condition never holds.
Instead, check that boff.lnum has just moved to or past w_botline by
comparing its previous value with w_botline.
Also make a similar change to the loff.lnum check above for symmetry.
That one doesn't change behavior, as topline_back() sets loff.lnum to
the first line of a fold.
related: neovim/neovim#41122
closes: vim/vim#20923
https://github.com/vim/vim/commit/aee686334c2137f8a94b04de130a3f51d928a7ed
Diffstat (limited to 'runtime/plugin/python_setup.vim')
0 files changed, 0 insertions, 0 deletions