mirror of
https://github.com/vim/vim.git
synced 2025-09-29 04:34:16 -04:00
patch 8.1.0277: 'incsearch' highlighting wrong in a few cases
Problem: 'incsearch' highlighting wrong in a few cases. Solution: Fix using last search pattern. Restore highlighting when changing command. (issue #3321)
This commit is contained in:
9
src/testdir/dumps/Test_incsearch_substitute_02.dump
Normal file
9
src/testdir/dumps/Test_incsearch_substitute_02.dump
Normal file
@@ -0,0 +1,9 @@
|
||||
|f+0&#ffffff0|o@1| |1| @64
|
||||
|f|o@1| |2| @64
|
||||
|f|o@1| |3| @64
|
||||
|f+1&&|o@1| +0&&|4| @64
|
||||
|f+0&#ffff4012|o@1| +0&#ffffff0|5| @64
|
||||
|f+0&#ffff4012|o@1| +0&#ffffff0|6| @64
|
||||
|f|o@1| |7| @64
|
||||
|f|o@1| |8| @64
|
||||
|:|.|,|.|+|2|s|/@1> @60
|
9
src/testdir/dumps/Test_incsearch_substitute_03.dump
Normal file
9
src/testdir/dumps/Test_incsearch_substitute_03.dump
Normal file
@@ -0,0 +1,9 @@
|
||||
|f+0&#ffff4012|o@1| +0&#ffffff0|1| @64
|
||||
|f+0&#ffff4012|o@1| +0&#ffffff0|2| @64
|
||||
|f+0&#ffff4012|o@1| +0&#ffffff0|3| @64
|
||||
|f+0&#ffff4012|o@1| +0&#ffffff0|4| @64
|
||||
|f+0&#ffff4012|o@1| +0&#ffffff0|5| @64
|
||||
|f+0&#ffff4012|o@1| +0&#ffffff0|6| @64
|
||||
|f+0&#ffff4012|o@1| +0&#ffffff0|7| @64
|
||||
|f+0&#ffff4012|o@1| +0&#ffffff0|8| @64
|
||||
|:|.|,|.|+|2|s|/> @61
|
@@ -839,6 +839,7 @@ func Test_incsearch_substitute_dump()
|
||||
sleep 100m
|
||||
|
||||
" Need to send one key at a time to force a redraw.
|
||||
" Select three lines at the cursor with typed pattern.
|
||||
call term_sendkeys(buf, ':.,.+2s/')
|
||||
sleep 100m
|
||||
call term_sendkeys(buf, 'f')
|
||||
@@ -846,7 +847,21 @@ func Test_incsearch_substitute_dump()
|
||||
call term_sendkeys(buf, 'o')
|
||||
sleep 100m
|
||||
call term_sendkeys(buf, 'o')
|
||||
sleep 100m
|
||||
call VerifyScreenDump(buf, 'Test_incsearch_substitute_01', {})
|
||||
call term_sendkeys(buf, "\<Esc>")
|
||||
|
||||
" Select three lines at the cursor using previous pattern.
|
||||
call term_sendkeys(buf, "/foo\<CR>")
|
||||
sleep 100m
|
||||
call term_sendkeys(buf, ':.,.+2s//')
|
||||
sleep 100m
|
||||
call VerifyScreenDump(buf, 'Test_incsearch_substitute_02', {})
|
||||
|
||||
" Deleting last slash should remove the match.
|
||||
call term_sendkeys(buf, "\<BS>")
|
||||
sleep 100m
|
||||
call VerifyScreenDump(buf, 'Test_incsearch_substitute_03', {})
|
||||
|
||||
call term_sendkeys(buf, "\<Esc>")
|
||||
call StopVimInTerminal(buf)
|
||||
|
Reference in New Issue
Block a user