aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/optionstr.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/nvim/optionstr.c')
-rw-r--r--src/nvim/optionstr.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/src/nvim/optionstr.c b/src/nvim/optionstr.c
index 518208a037..f80926726a 100644
--- a/src/nvim/optionstr.c
+++ b/src/nvim/optionstr.c
@@ -2100,7 +2100,13 @@ const char *did_set_showbreak(optset_T *args)
/// The 'showcmdloc' option is changed.
const char *did_set_showcmdloc(optset_T *args FUNC_ATTR_UNUSED)
{
- return did_set_opt_strings(p_sloc, p_sloc_values, true);
+ const char *errmsg = did_set_opt_strings(p_sloc, p_sloc_values, false);
+
+ if (errmsg == NULL) {
+ comp_col();
+ }
+
+ return errmsg;
}
int expand_set_showcmdloc(optexpand_T *args, int *numMatches, char ***matches)
@@ -2473,9 +2479,8 @@ const char *did_set_virtualedit(optset_T *args)
} else if (strcmp(ve, args->os_oldval.string.data) != 0) {
// Recompute cursor position in case the new 've' setting
// changes something.
- validate_virtcol_win(win);
- // XXX: this only works when win == curwin
- coladvance(win->w_virtcol);
+ validate_virtcol(win);
+ coladvance(win, win->w_virtcol);
}
}
return NULL;