diff options
author | Luuk van Baal <luukvbaal@gmail.com> | 2023-04-29 00:34:09 +0200 |
---|---|---|
committer | Luuk van Baal <luukvbaal@gmail.com> | 2023-05-02 13:11:47 +0200 |
commit | 35ed79a9150fed877e660395c64d6659bf0a07ec (patch) | |
tree | abd148a9ffa84cf96a4dcdf4eea64510aff1f4ba /src | |
parent | 7d5673b18b8b4ff085473b40fce317e760e48ce3 (diff) | |
download | rneovim-35ed79a9150fed877e660395c64d6659bf0a07ec.tar.gz rneovim-35ed79a9150fed877e660395c64d6659bf0a07ec.tar.bz2 rneovim-35ed79a9150fed877e660395c64d6659bf0a07ec.zip |
vim-patch:9.0.1435: scrolling too many lines when 'wrap' and 'diff' are set
Problem: Scrolling too many lines when 'wrap' and 'diff' are set.
Solution: Only scroll by screenlines for 'diff' when 'wrap' is not set.
(closes vim/vim#12211)
https://github.com/vim/vim/commit/38d867f041349e1400c2cce9cac06f59ae6ccbb1
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Diffstat (limited to 'src')
-rw-r--r-- | src/nvim/move.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/nvim/move.c b/src/nvim/move.c index 69245f2a67..b597853c13 100644 --- a/src/nvim/move.c +++ b/src/nvim/move.c @@ -1320,7 +1320,7 @@ static int scrolling_screenlines(bool byfold) { return (curwin->w_p_wrap && curwin->w_p_sms) || (byfold && hasAnyFolding(curwin)) - || curwin->w_p_diff; + || (curwin->w_p_diff && !curwin->w_p_wrap); } /// Scroll the current window up by "line_count" logical lines. "CTRL-E" |