mirror of
https://github.com/vim/vim.git
synced 2025-09-26 04:04:07 -04:00
patch 8.2.1727: a popup created with "cursorline" will ignore "firstline"
Problem: A popup created with "cursorline" will ignore "firstline". Solution: When both "cursorline" and "firstline" are present put the cursor on "firstline". (closes #7000) Add the "winid" argument to getcurpos().
This commit is contained in:
@@ -2520,7 +2520,19 @@ func Test_getcurpos_setpos()
|
||||
call assert_equal('6', @")
|
||||
call assert_equal(-1, setpos('.', test_null_list()))
|
||||
call assert_equal(-1, setpos('.', {}))
|
||||
|
||||
let winid = win_getid()
|
||||
normal G$
|
||||
let pos = getcurpos()
|
||||
wincmd w
|
||||
call assert_equal(pos, getcurpos(winid))
|
||||
|
||||
wincmd w
|
||||
close!
|
||||
|
||||
call assert_equal(getcurpos(), getcurpos(0))
|
||||
call assert_equal([0, 0, 0, 0, 0], getcurpos(-1))
|
||||
call assert_equal([0, 0, 0, 0, 0], getcurpos(1999))
|
||||
endfunc
|
||||
|
||||
" Test for glob()
|
||||
|
Reference in New Issue
Block a user