]> git.ipfire.org Git - thirdparty/vim.git/commit
patch 9.1.0611: ambiguous mappings not correctly resolved with modifyOtherKeys v9.1.0611
authorOleg Goncharov <goncharovoi@yandex.ru>
Tue, 23 Jul 2024 18:34:15 +0000 (20:34 +0200)
committerChristian Brabandt <cb@256bit.org>
Tue, 23 Jul 2024 18:42:02 +0000 (20:42 +0200)
commit56904f90d15853085552470a2fedcb6cadb62309
tree69447b9fefda86ef9e6ae456c735dcd85b03b218
parent38ce71c1c323716cc4b130dbb3e8837a8b9a710b
patch 9.1.0611: ambiguous mappings not correctly resolved with modifyOtherKeys

Problem:  ambiguous mappings not correctly resolved with modifyOtherKeys
Solution: Check for termcode when an upper case mapping is received and
          does not match (Oleg Goncharov)

Fix for mapping processing when capital leters are represented with terminal codes.

Problem: there are two mappings and
1) the first mapping is substring of the second,
2) the first non-matching letter is capital,
3) capital letters are represented with termcodes "ESC[27;2;<ascii code>~" in given system
then first mapping is applied instead of second.

Example:

    :map B b
    :map BBB blimp!

and then

    BBB -> bbb

instead of

    BBB -> blimp!

Solution: force termcodes check if capital letter does not match.

closes: #15251

Signed-off-by: Oleg Goncharov <goncharovoi@yandex.ru>
Signed-off-by: Christian Brabandt <cb@256bit.org>
src/getchar.c
src/testdir/test_termcodes.vim
src/testdir/view_util.vim
src/version.c