Mercurial > vim
changeset 22000:afa3080a96ae v8.2.1549
patch 8.2.1549: "r" fails if 'esckeys' is off and modifyOtherKeys is used
Commit: https://github.com/vim/vim/commit/ca774f67534e6d1843fda9d1dc9a899972d27577
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun Aug 30 20:46:38 2020 +0200
patch 8.2.1549: "r" fails if 'esckeys' is off and modifyOtherKeys is used
Problem: The "r" command fails for keys with modifiers if 'esckeys' is off
and modifyOtherKeys is used. (Lauri Tirkkonen)
Solution: Temporarily disable bracketed paste and modifyOtherKeys if
'esckeys' is off. (closes #6809)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sun, 30 Aug 2020 21:00:03 +0200 |
parents | d89bfc708784 |
children | b77a58769130 |
files | src/normal.c src/version.c |
diffstat | 2 files changed, 16 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/src/normal.c +++ b/src/normal.c @@ -895,9 +895,23 @@ getcount: if (lang && curbuf->b_p_iminsert == B_IMODE_IM) im_set_active(TRUE); #endif + if ((State & INSERT) && !p_ek) + { + // Disable bracketed paste and modifyOtherKeys here, we won't + // recognize the escape sequences with 'esckeys' off. + out_str(T_BD); + out_str(T_CTE); + } *cp = plain_vgetc(); + if ((State & INSERT) && !p_ek) + { + // Re-enable bracketed paste mode and modifyOtherKeys + out_str(T_BE); + out_str(T_CTI); + } + if (langmap_active) { // Undo the decrement done above