Mercurial > vim
diff src/testdir/test_textprop.vim @ 33021:2b47322be0d1 v9.0.1802
patch 9.0.1802: Multiline regex with Visual selection fails with virtual text
Commit: https://github.com/vim/vim/commit/e3daa06be1a3ba7ced0735582467d092275e591c
Author: zeertzjq <zeertzjq@outlook.com>
Date: Sun Aug 27 19:11:46 2023 +0200
patch 9.0.1802: Multiline regex with Visual selection fails with virtual text
Problem: Multiline regex with Visual selection fails when Visual
selection contains virtual text after last char.
Solution: Only include virtual text after last char when getting full
line length.
closes: #12908
Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Sun, 27 Aug 2023 19:15:09 +0200 |
parents | 7d0357f70cf8 |
children | d03841a271aa |
line wrap: on
line diff
--- a/src/testdir/test_textprop.vim +++ b/src/testdir/test_textprop.vim @@ -3235,6 +3235,14 @@ func Test_props_with_text_empty_line() call VerifyScreenDump(buf, 'Test_prop_with_text_empty_line_4', {}) call term_sendkeys(buf, "j") call VerifyScreenDump(buf, 'Test_prop_with_text_empty_line_5', {}) + call term_sendkeys(buf, "0\<C-V>2l2k") + call VerifyScreenDump(buf, 'Test_prop_with_text_empty_line_6', {}) + call term_sendkeys(buf, "\<Esc>/aaa\\n\\%V\<CR>") + call VerifyScreenDump(buf, 'Test_prop_with_text_empty_line_7', {}) + call term_sendkeys(buf, "3ggic") + call VerifyScreenDump(buf, 'Test_prop_with_text_empty_line_8', {}) + call term_sendkeys(buf, "\<Esc>/aaa\\nc\\%V\<CR>") + call VerifyScreenDump(buf, 'Test_prop_with_text_empty_line_9', {}) call StopVimInTerminal(buf) endfunc