psychojs
psychojs copied to clipboard
Different values returned by getKeys on PsychoPy and PsychoJS
Implementations of getKeys are different between PsychoJS (returns keyboard entities) and PsychoPy (returns actual keys). Concretely this means the following. If you set your keyboard layout to german, there is an U-umlaut (ü) at the location of the left-bracket key ([). In PsychoPy, getKeys returns "ü", but PsychoJS returns "leftbracket".
Demo: https://gitlab.pavlovia.org/tpronk/e2e_map_key https://run.pavlovia.org/tpronk/e2e_map_key/
I'm surprised about the getKeys from PsychoPy here. In general, we aim to return the name of the key not the character. I might need to check with you the code that you're using (because there are several forms of getKeys() calls depending on backend being used)
Little follow-up: I verified this issue on my Win10 device on Chrome and Firefox. The new link to the experiment I use to test it is: https://run.pavlovia.org/tpronk/demo_map_key/