mirror of
https://github.com/neovim/neovim.git
synced 2025-10-04 17:06:30 +00:00
vim-patch:9.1.0145: v:echospace not correct when 'showcmdloc' != last (#27682)
Problem: the amount of available space (v:echospace) on the command
line is not correct when showcmdloc is drawn into the
statusline or tabline.
Solution: only add SHOWCMD_COLS to the shown command column when
'showcmdloc' is set to last (Sam-programs)
closes: vim/vim#14108
062141b1a7
Co-authored-by: Sam-programs <130783534+Sam-programs@users.noreply.github.com>
This commit is contained in:
@@ -1178,7 +1178,7 @@ void comp_col(void)
|
||||
sc_col = ru_col;
|
||||
}
|
||||
}
|
||||
if (p_sc) {
|
||||
if (p_sc && *p_sloc == 'l') {
|
||||
sc_col += SHOWCMD_COLS;
|
||||
if (!p_ru || last_has_status) { // no need for separating space
|
||||
sc_col++;
|
||||
|
@@ -2100,6 +2100,7 @@ const char *did_set_showbreak(optset_T *args)
|
||||
/// The 'showcmdloc' option is changed.
|
||||
const char *did_set_showcmdloc(optset_T *args FUNC_ATTR_UNUSED)
|
||||
{
|
||||
comp_col();
|
||||
return did_set_opt_strings(p_sloc, p_sloc_values, true);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user