Unable to switch tabs using a non-QWERTY keyboard
- iTerm2 version: 3.1.git.e449874d
- OS version: 10.12.3 (16D32)
iTerm has never allowed to to switch tabs using the shortcut Command + number as I use an AZERTY keyboard. This problem has always existed, I have downloaded the project to find the root cause of the problem but I am not sure how to solve it.
To reproduce the issue:
- If you have a non-QWERTY keyboard with numbers that are not directly accessible (you need to press Shift), use it. Otherwise you can use the macOS Preferences to set your keyboard to e.g. AZERTY even if it is a QWERTY keyboard. I have done the reverse to see how works iTerm with a QWERTY keyboard.
- Open multiple iTerm tabs and play with Command + number, it will do nothing.
This line has an issue with keyboards that need Shift to effectively compose a number. The value
int digit = [[event charactersIgnoringModifiers] intValue]; returns 0 if I just do a
Command + key that has a number in it on an AZERTY keyboard. If I do
Command + shift + key that has a number in it the function will not be fired.
What should have happened:
Command + key that has a number in it on an AZERTY keyboard (or any keyboard where the numbers are not directly accessible) should still give the number on the key and thus allow the user to switch tabs using this keyboard shortcut.