Mercurial > vim
comparison src/testdir/test_listener.vim @ 19534:36ec10251b2b v8.2.0324
patch 8.2.0324: text property not updated correctly when inserting/deleting
Commit: https://github.com/vim/vim/commit/12f20038714928bfecdeee31ed1f927324542034
Author: Bram Moolenaar <Bram@vim.org>
Date: Wed Feb 26 22:06:00 2020 +0100
patch 8.2.0324: text property not updated correctly when inserting/deleting
Problem: Text property not updated correctly when inserting/deleting.
Solution: Use the right column when deleting. Make zero-width text
properties respect start_incl and end_incl. (Axel Forsman,
closes #5696, closes #5679)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Wed, 26 Feb 2020 22:15:04 +0100 |
parents | af795b6a2624 |
children | f3162c3ed128 |
comparison
equal
deleted
inserted
replaced
19533:ffe25b424609 | 19534:36ec10251b2b |
---|---|
324 unlet g:gotCalled | 324 unlet g:gotCalled |
325 | 325 |
326 bwipe! | 326 bwipe! |
327 delfunc Listener | 327 delfunc Listener |
328 endfunc | 328 endfunc |
329 | |
330 func Test_col_after_deletion_moved_cur() | |
331 func Listener(bufnr, start, end, added, changes) | |
332 call assert_equal([#{lnum: 1, end: 2, added: 0, col: 2}], a:changes) | |
333 endfunc | |
334 new | |
335 call setline(1, ['foo']) | |
336 let lid = listener_add('Listener') | |
337 call feedkeys("lD", 'xt') | |
338 call listener_flush() | |
339 bwipe! | |
340 delfunc Listener | |
341 endfunc |