vim-patch:9.0.1000: with 'smoothscroll' skipcol may be reset unnecessarily

Problem:    With 'smoothscroll' skipcol may be reset unnecessarily.
Solution:   Check the line does actually fit in the window.

b21b8e9ed0

Co-authored-by: Bram Moolenaar <Bram@vim.org>
This commit is contained in:
Luuk van Baal
2023-04-28 12:36:11 +02:00
parent c25fd85c2e
commit 6fd7e3bea4
3 changed files with 12 additions and 9 deletions

View File

@@ -494,14 +494,7 @@ describe('smoothscroll', function()
]])
-- 'scrolloff' set to 2, scrolling down, cursor moves screen line up
feed('<C-E>gj<C-Y>')
screen:expect([[
<<<ots of text with lots of text with lo|
ts of text with lots of text with lots o|
f text wi^th lots of text with lots of te|
xt with lots of text with lots of text w|
ith lots of text with lots of text with |
|
]])
screen:expect_unchanged()
-- 'scrolloff' set to 0, move cursor down one line. Cursor should move properly,
-- and since this is a really long line, it will be put on top of the screen.
exec('set scrolloff=0')