mirror of
https://github.com/neovim/neovim.git
synced 2025-09-26 21:18:34 +00:00
bufhl: use extmark column adjustment for bufhl
NB: this is not the final implementation. Bufhl should be made a part of the extmark tree, so that "start" adjustment just works automatically. But "stop" will still need some ad-hoc trickery, until extended marks natively support ranges (hopefully sooner than forever).
This commit is contained in:
@@ -5599,9 +5599,10 @@ insertchar (
|
||||
do_digraph(-1); /* clear digraphs */
|
||||
do_digraph(buf[i-1]); /* may be the start of a digraph */
|
||||
buf[i] = NUL;
|
||||
colnr_T col_start = curwin->w_cursor.col;
|
||||
ins_str(buf);
|
||||
extmark_col_adjust(curbuf, curwin->w_cursor.lnum,
|
||||
(colnr_T)(curwin->w_cursor.col + 1), 0,
|
||||
(colnr_T)(col_start + 1), 0,
|
||||
(long)STRLEN(buf), kExtmarkUndo);
|
||||
if (flags & INSCHAR_CTRLV) {
|
||||
redo_literal(*buf);
|
||||
|
Reference in New Issue
Block a user