This patch checks if the ⇥, CapsLock and Space keys are pressed, to prevent keymaps that do not use them as modifiers to execute.
Problem
Any regular key used as a modifier, gets ignored when deciding which keymap to execute. This way keymaps that do not have a custom modifier are executed even if there is one pressed.
Example using Space as middle mouse button emulation: In sculpt mode, Space+left mouse button will start sculpt instead of rotate view. (Note: Sculpt will cancel quickly, cause of bug addressed in D12863)
Cause
Currently customs modifiers are ignored to allow key queuing for fast workflow.
E.g. Quickly select all and move. Can press A and then G before lifting A.
Solution
Only consider some custom modifiers that should not be an issue in the current workflow, and improve the use of them as modifiers.
Limitations
- Only the keys specified can be freely used as keymodifiers.
- May affect speed in parts of workflow. e.g. Play-pause(Space) and object mode (⇥) in quick succession (if keys press overlap).
Alternative
An other option is to consider all keys. This would improve the use of all keys as custom key modifiers; but probably would cause issues in workflow speed, when keys overlap.
Related but not part of this patch: Repeating keys cause some issues in execution of keymaps, which is partially addressed in D12863; but I was not able to completely pinpoint this issue. The keymap (I'm aware of) that will still have problem is view3d.view_center_pick, when used with Space, Alt and left mouse button key combination set.
From a couple of searches cannot find a bug report for this, or any talk about this issue. As such, User Interface also need to review and approve this change.
Motivation
Use of Space as middle mouse button emulation. The ⇥ and CapsLock were included to allow more freedom in keymaps creation.