From 53ba05b09075f14227f9be831a22ed16f7cc26b2 Mon Sep 17 00:00:00 2001 From: Gary Johnson Date: Mon, 26 Jul 2021 22:19:10 +0200 Subject: patch 8.2.3227: 'virtualedit' can only be set globally Problem: 'virtualedit' can only be set globally. Solution: Make 'virtualedit' global-local. (Gary Johnson, closes #8638) --- src/drawscreen.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/drawscreen.c') diff --git a/src/drawscreen.c b/src/drawscreen.c index 49615bda60..36aad637b2 100644 --- a/src/drawscreen.c +++ b/src/drawscreen.c @@ -2006,21 +2006,21 @@ win_update(win_T *wp) { colnr_T fromc, toc; #if defined(FEAT_LINEBREAK) - int save_ve_flags = ve_flags; + int save_ve_flags = curbuf->b_ve_flags; if (curwin->w_p_lbr) - ve_flags = VE_ALL; + curbuf->b_ve_flags = VE_ALL; #endif getvcols(wp, &VIsual, &curwin->w_cursor, &fromc, &toc); ++toc; #if defined(FEAT_LINEBREAK) - ve_flags = save_ve_flags; + curbuf->b_ve_flags = save_ve_flags; #endif // Highlight to the end of the line, unless 'virtualedit' has // "block". if (curwin->w_curswant == MAXCOL) { - if (ve_flags & VE_BLOCK) + if (get_ve_flags() & VE_BLOCK) { pos_T pos; int cursor_above = -- cgit v1.2.3