Mercurial > vim
diff src/testdir/test_textprop.vim @ 28931:b57caac54649 v8.2.4988
patch 8.2.4988: textprop in wrong position when replacing multi-byte chars
Commit: https://github.com/vim/vim/commit/0d534d9cf2ae95fc85ef7fe048d9ff590586a6a6
Author: LemonBoy <thatlemon@gmail.com>
Date: Sat May 21 11:20:42 2022 +0100
patch 8.2.4988: textprop in wrong position when replacing multi-byte chars
Problem: Textprop in wrong position when replacing multi-byte chars.
Solution: Adjust textprop position. (closes https://github.com/vim/vim/issues/10461)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sat, 21 May 2022 12:30:03 +0200 |
parents | 78ebb50d6fcb |
children | b3828315a0d9 |
line wrap: on
line diff
--- a/src/testdir/test_textprop.vim +++ b/src/testdir/test_textprop.vim @@ -573,6 +573,13 @@ func Test_prop_replace() call assert_equal('yyyex xyyoxx', getline(1)) call assert_equal(expected, prop_list(1)) + " Replace three 1-byte chars with three 2-byte ones. + exe "normal 0l3rø" + call assert_equal('yøøøx xyyoxx', getline(1)) + let expected[0].length += 3 + let expected[1].col += 3 + call assert_equal(expected, prop_list(1)) + call DeletePropTypes() bwipe! set bs&