comparison src/testdir/test_signs.vim @ 19447:5b82f041dbbb v8.2.0281

patch 8.2.0281: two placed signs in the same line are not combined Commit: https://github.com/vim/vim/commit/a2f6e42ded067df8ee682c15aa246491a389b1a0 Author: Bram Moolenaar <Bram@vim.org> Date: Wed Feb 19 17:13:04 2020 +0100 patch 8.2.0281: two placed signs in the same line are not combined Problem: Two placed signs in the same line are not combined. E.g. in the terminal debugger a breakpoint and the PC cannot be both be displayed. Solution: Combine the sign column and line highlight attributes.
author Bram Moolenaar <Bram@vim.org>
date Wed, 19 Feb 2020 17:15:04 +0100
parents 5cd0986ab02e
children 116c7bd5e980
comparison
equal deleted inserted replaced
19446:972f89992ae8 19447:5b82f041dbbb
1740 1740
1741 let lines =<< trim END 1741 let lines =<< trim END
1742 call setline(1, [repeat('x', 75), 'mmmm', 'yyyy']) 1742 call setline(1, [repeat('x', 75), 'mmmm', 'yyyy'])
1743 call cursor(2,1) 1743 call cursor(2,1)
1744 sign define s1 texthl=Search text==> 1744 sign define s1 texthl=Search text==>
1745 sign define s2 linehl=Pmenu
1745 redraw 1746 redraw
1746 sign place 10 line=2 name=s1 1747 sign place 10 line=2 name=s1
1747 END 1748 END
1748 call writefile(lines, 'XtestSigncolumn') 1749 call writefile(lines, 'XtestSigncolumn')
1749 let buf = RunVimInTerminal('-S XtestSigncolumn', {'rows': 6}) 1750 let buf = RunVimInTerminal('-S XtestSigncolumn', {'rows': 6})
1751 1752
1752 " Change the sign text 1753 " Change the sign text
1753 call term_sendkeys(buf, ":sign define s1 text=-)\<CR>") 1754 call term_sendkeys(buf, ":sign define s1 text=-)\<CR>")
1754 call VerifyScreenDump(buf, 'Test_sign_cursor_2', {}) 1755 call VerifyScreenDump(buf, 'Test_sign_cursor_2', {})
1755 1756
1757 " Also place a line HL sign
1758 call term_sendkeys(buf, ":sign place 11 line=2 name=s2\<CR>")
1759 call VerifyScreenDump(buf, 'Test_sign_cursor_3', {})
1760
1756 " update cursor position calculation 1761 " update cursor position calculation
1757 call term_sendkeys(buf, "lh") 1762 call term_sendkeys(buf, "lh")
1763 call term_sendkeys(buf, ":sign unplace 11\<CR>")
1758 call term_sendkeys(buf, ":sign unplace 10\<CR>") 1764 call term_sendkeys(buf, ":sign unplace 10\<CR>")
1759 call VerifyScreenDump(buf, 'Test_sign_cursor_3', {}) 1765 call VerifyScreenDump(buf, 'Test_sign_cursor_4', {})
1760
1761 1766
1762 " clean up 1767 " clean up
1763 call StopVimInTerminal(buf) 1768 call StopVimInTerminal(buf)
1764 call delete('XtestSigncolumn') 1769 call delete('XtestSigncolumn')
1765 endfunc 1770 endfunc