Merge #15626 vim-patch:8.1.{2281,2283},8.2.{2903,3391,3397}

This commit is contained in:
Justin M. Keyes
2021-09-10 08:43:45 -07:00
committed by GitHub
14 changed files with 131 additions and 42 deletions

View File

@@ -5726,16 +5726,19 @@ void cursor_pos_info(dict_T *dict)
}
if (l_VIsual_mode == Ctrl_V) {
char_u * saved_sbr = p_sbr;
char_u *const saved_sbr = p_sbr;
char_u *const saved_w_sbr = curwin->w_p_sbr;
// Make 'sbr' empty for a moment to get the correct size.
p_sbr = empty_option;
curwin->w_p_sbr = empty_option;
oparg.is_VIsual = true;
oparg.motion_type = kMTBlockWise;
oparg.op_type = OP_NOP;
getvcols(curwin, &min_pos, &max_pos,
&oparg.start_vcol, &oparg.end_vcol);
p_sbr = saved_sbr;
curwin->w_p_sbr = saved_w_sbr;
if (curwin->w_curswant == MAXCOL) {
oparg.end_vcol = MAXCOL;
}