Mercurial > vim
view src/testdir/test_interrupt.vim @ 34298:5525b635ed4a v9.1.0084
patch 9.1.0084: Visual hl wrong when it ends before multibyte 'showbreak'
Commit: https://github.com/vim/vim/commit/df23d7f4bd7546f3152ea003856525591218565b
Author: zeertzjq <zeertzjq@outlook.com>
Date: Fri Feb 9 18:14:12 2024 +0100
patch 9.1.0084: Visual hl wrong when it ends before multibyte 'showbreak'
Problem: Visual hl wrong when it ends before multibyte 'showbreak'.
(lacygoil)
Solution: Use vcol_sbr instead of adding n_extra.
(zeertzjq)
fixes: #11272
closes: #13996
Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Fri, 09 Feb 2024 18:30:04 +0100 |
parents | 860f148e7a64 |
children |
line wrap: on
line source
" Test behavior of interrupt() let s:bufwritepre_called = 0 let s:bufwritepost_called = 0 func s:bufwritepre() let s:bufwritepre_called = 1 call interrupt() endfunction func s:bufwritepost() let s:bufwritepost_called = 1 endfunction func Test_interrupt() new Xinterrupt let n = 0 try au BufWritePre Xinterrupt call s:bufwritepre() au BufWritePost Xinterrupt call s:bufwritepost() w! catch /^Vim:Interrupt$/ endtry call assert_equal(1, s:bufwritepre_called) call assert_equal(0, s:bufwritepost_called) call assert_equal(0, filereadable('Xinterrupt')) au! BufWritePre au! BufWritePost endfunc " vim: shiftwidth=2 sts=2 expandtab