vim-patch:9.0.1512: inserting lines when scrolling with 'smoothscroll' set

Problem:    Inserting lines when scrolling with 'smoothscroll' set.
Solution:   Adjust line height computation for w_skipcol. (Luuk van Baal,
            closes vim/vim#12350)

c8502f9b88
This commit is contained in:
Luuk van Baal
2023-05-06 17:33:42 +02:00
parent ca5a810c4a
commit 3b2bd8d69e
4 changed files with 59 additions and 5 deletions

View File

@@ -695,6 +695,30 @@ describe('smoothscroll', function()
]])
end)
-- oldtest: Test_smoothscroll_ins_lines()
it("this was unnecessarily inserting lines", function()
screen:try_resize(40, 6)
exec([=[
set wrap smoothscroll scrolloff=0 conceallevel=2 concealcursor=nc
call setline(1, [
\'line one' .. 'with lots of text in one line '->repeat(2),
\'line two',
\'line three',
\'line four',
\'line five'
\])
]=])
feed('<C-E>gjgk')
screen:expect([[
<<<lots of text in one line^ |
line two |
line three |
line four |
line five |
|
]])
end)
it("works with virt_lines above and below", function()
screen:try_resize(55, 7)
exec([=[