I am remapping the CapsLock key to the Control key.
If I are remapping on OS, before #277, you could detect all control key presses by using tetra::input::is_key_modifier_down(ctx, KeyModifier::Ctrl)
277 Onwards, I can use tetra::input::get_key_with_label to check the physical key after remapping, but this method can only return a single key due to SDL2 specification.
Therefore, there is no way to detect when multiple physical keys are mapped to a single logical key.
This PR adds an iterator to Tetra that enumerates all items, and the following code solves this problem.
I am remapping the CapsLock key to the Control key. If I are remapping on OS, before #277, you could detect all control key presses by using
tetra::input::is_key_modifier_down(ctx, KeyModifier::Ctrl)
277 Onwards, I can use
tetra::input::get_key_with_label
to check the physical key after remapping, but this method can only return a single key due to SDL2 specification.Therefore, there is no way to detect when multiple physical keys are mapped to a single logical key.
This PR adds an iterator to Tetra that enumerates all items, and the following code solves this problem.