diff options
author | luukvbaal <luukvbaal@gmail.com> | 2023-11-14 23:28:56 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-11-15 06:28:56 +0800 |
commit | f4d95c05b98c2ce2f70e73d4fe6a03cf54ed44cd (patch) | |
tree | ed99e027e46aea8871afc076a4ec5784843a7e31 /test/functional/legacy/scroll_opt_spec.lua | |
parent | 9e2248ab586c5e5854da68b5310755ea3557e6c9 (diff) | |
download | rneovim-f4d95c05b98c2ce2f70e73d4fe6a03cf54ed44cd.tar.gz rneovim-f4d95c05b98c2ce2f70e73d4fe6a03cf54ed44cd.tar.bz2 rneovim-f4d95c05b98c2ce2f70e73d4fe6a03cf54ed44cd.zip |
vim-patch:9.0.2105: skipcol not reset when topline changed (#26042)
Problem: Skipcol is not reset when topline changed scrolling cursor to top
Solution: reset skipcol
closes: vim/vim#13528
https://github.com/vim/vim/commit/bb800a7907209f7d349f87b76b3b9ca30b416298
Diffstat (limited to 'test/functional/legacy/scroll_opt_spec.lua')
-rw-r--r-- | test/functional/legacy/scroll_opt_spec.lua | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/test/functional/legacy/scroll_opt_spec.lua b/test/functional/legacy/scroll_opt_spec.lua index 5b4bfb3caa..d4e4702f5e 100644 --- a/test/functional/legacy/scroll_opt_spec.lua +++ b/test/functional/legacy/scroll_opt_spec.lua @@ -982,6 +982,31 @@ describe('smoothscroll', function() ]]) end) + -- oldtest: Test_smoothscroll_cursor_top() + it('resets skipcol when scrolling cursor to top', function() + screen:try_resize(40, 12) + exec([[ + set smoothscroll scrolloff=2 + new | 11resize | wincmd j + call setline(1, ['line1', 'line2', 'line3'->repeat(20), 'line4']) + exe "norm G3\<C-E>k" + ]]) + screen:expect([[ + | + [No Name] | + line1 | + line2 | + ^line3line3line3line3line3line3line3line3| + line3line3line3line3line3line3line3line3| + line3line3line3line3 | + line4 | + ~ | + ~ | + [No Name] [+] | + | + ]]) + end) + it("works with virt_lines above and below", function() screen:try_resize(55, 7) exec([=[ |