From: Bram Moolenaar Date: Mon, 12 Sep 2022 19:35:28 +0000 (+0100) Subject: patch 9.0.0453: on an AZERTY keyboard digit keys get the shift modifier X-Git-Tag: v9.0.0453 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=83a19c5fda0556330860899bfb484addf9178cd0;p=vim patch 9.0.0453: on an AZERTY keyboard digit keys get the shift modifier Problem: On an AZERTY keyboard digit keys get the shift modifier. Solution: Remove the shift modifier from digit keys. (closes #11109) --- diff --git a/src/misc2.c b/src/misc2.c index 165a08080..841940225 100644 --- a/src/misc2.c +++ b/src/misc2.c @@ -1540,7 +1540,8 @@ may_adjust_key_for_ctrl(int modifiers, int key) * When Ctrl is also used and are different, but should * be . Same for and . * Also for and . - * This includes all printable ASCII characters except numbers and a-z. + * This includes all printable ASCII characters except a-z. + * Digits are included because with AZERTY the Shift key is used to get them. */ int may_remove_shift_modifier(int modifiers, int key) @@ -1550,6 +1551,7 @@ may_remove_shift_modifier(int modifiers, int key) || modifiers == (MOD_MASK_SHIFT | MOD_MASK_META)) && ((key >= '!' && key <= '/') || (key >= ':' && key <= 'Z') + || vim_isdigit(key) || (key >= '[' && key <= '`') || (key >= '{' && key <= '~'))) return modifiers & ~MOD_MASK_SHIFT; diff --git a/src/version.c b/src/version.c index 26b8bf3a4..9701d6d82 100644 --- a/src/version.c +++ b/src/version.c @@ -703,6 +703,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 453, /**/ 452, /**/