fix(marks): handle composing in inline virt_text with 'nowrap' (#32477)

This commit is contained in:
zeertzjq
2025-02-16 22:54:32 +08:00
committed by GitHub
parent 8452032554
commit 906ad04ddd
2 changed files with 13 additions and 13 deletions

View File

@@ -914,10 +914,10 @@ static void handle_inline_virtual_text(win_T *wp, winlinevars_T *wlv, ptrdiff_t
int cells_to_skip = wlv->skip_cells;
// Skip cells in the text.
while (cells_to_skip > 0) {
int clen = utf_ptr2len(wlv->p_extra);
int c_len = utfc_ptr2len(wlv->p_extra);
cells_to_skip -= utf_ptr2cells(wlv->p_extra);
wlv->p_extra += clen;
wlv->n_extra -= clen;
wlv->p_extra += c_len;
wlv->n_extra -= c_len;
wlv->n_attr--;
}
// If a double-width char doesn't fit, pad with space.