diff options
author | zeertzjq <zeertzjq@outlook.com> | 2024-03-16 15:03:33 +0100 |
---|---|---|
committer | Christian Brabandt <cb@256bit.org> | 2024-03-16 15:03:33 +0100 |
commit | d0c1b7723f7e73763597af2f97a53d94ab7ed020 (patch) | |
tree | 241675d6a8328063a55002fc96a07684320b70b9 /src/drawscreen.c | |
parent | 9e7f1fc2f159d58b2a4cd4b7060bead126fead49 (diff) |
patch 9.1.0184: Cursor pos wrong when clicking with conceal and wrapv9.1.0184
Problem: Cursor position wrong when clicking with conceal and wrap.
Solution: Use the virtual column of the last char for ScreenCols[] in
boguscols. Remove use of MAXCOL in ScreenCols[]. Rename
third argument of wlv_screen_line() to "clear_end" as that's
clearer what it does (zeertzjq).
related: 14192
closes: #14200
Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
Diffstat (limited to 'src/drawscreen.c')
-rw-r--r-- | src/drawscreen.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/drawscreen.c b/src/drawscreen.c index 3d6c230c19..f8818ff1aa 100644 --- a/src/drawscreen.c +++ b/src/drawscreen.c @@ -1028,7 +1028,8 @@ redraw_win_toolbar(win_T *wp) } wp->w_winbar_items[item_idx].wb_menu = NULL; // end marker - screen_line(wp, wp->w_winrow, wp->w_wincol, wp->w_width, wp->w_width, 0); + screen_line(wp, wp->w_winrow, wp->w_wincol, wp->w_width, wp->w_width, -1, + 0); } #endif @@ -1363,7 +1364,7 @@ fold_line( #endif screen_line(wp, row + W_WINROW(wp), wp->w_wincol, - wp->w_width, wp->w_width, 0); + wp->w_width, wp->w_width, -1, 0); // Update w_cline_height and w_cline_folded if the cursor line was // updated (saves a call to plines() later). @@ -3049,7 +3050,7 @@ redraw_asap(int type) mch_memmove(ScreenLines2 + off, screenline2 + r * cols, (size_t)cols * sizeof(schar_T)); - screen_line(curwin, cmdline_row + r, 0, cols, cols, 0); + screen_line(curwin, cmdline_row + r, 0, cols, cols, -1, 0); } ret = 4; } |