You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Yes I replicated the same issue in GLFW, if I run the gears example then when I press the capslock key nothing happens, but when I press the physical escape key then the gears program will quit. The gears code has
case GLFW_KEY_ESCAPE:
glfwSetWindowShouldClose(window, GLFW_TRUE);
But I also have the same issue when I run my game in a web browser via wasm. I would have thought that the browser would handle key remappings correctly. I guess there is little that ebiten can do about the situation with the browser.
Ebitengine Version
2.7.2
Operating System
Go Version (
go version
)go version go1.22.2 linux/amd64
What steps will reproduce the problem?
Swap escape and capslock with this command
press the capslock key in the game, and then invoke inpututil.AppendPressedKeys(keys).
What is the expected result?
The keys array should contain ebiten.KeyEscape, but instead it contains ebiten.KeyCapsLock
What happens instead?
Keys array contains ebiten.KeyCapsLock
Anything else you feel useful to add?
This situation works in SDL2, when I press the capslock key the key event correctly has event.key.keysym.sym == SDLK_ESCAPE.
Maybe the issue is in how the glfx.x11.keycodes array is set up, although the code looks plausible in that it queries xkb.
ebiten/internal/glfw/x11_init_linbsd.c
Line 197 in 13d15b0
FWIW this is what
xev -event keyboard
shows for me (after having swapped escape and capslock with the command above)Press capslock:
Press escape:
The text was updated successfully, but these errors were encountered: