Replies: 1 comment
-
YES! Thanks for asking! In my experience, altgr was incorrectly handled by winit, it was fixed in winit, come help me #8745. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hey all. I'm working on an app which needs a simple text-box with user input. Not a complex text editor -- just accept keystrokes into a text file and save it/load it later.
I have looked into tools like
egui
, which I believe can do the job -- but I am curious if vanilla Bevy can work. I am trying to avoid adding dependencies where possible.The road-block I am hitting is some keys do not have a
KeyCode
, so I cannot detect that key being pressed. For example!
,#
and$
are handled byEventReader<KeyboardInput>
asNone
KeyCodes whereas@
and all letters/numbers are handled fine.Example
Below is a simplified example demonstrating the problem:
Demo
In the screenshot I typed
ASDF
then1234
thenShift
+1234
.I have the
ScanCode
but I can't determine any way to programmatically correlate that with a keyboard character,Shift
-ed or otherwise.Prior art
I'm sure as work on UI and a Bevy Editor picks up this will be resolved.
It also seems like
winit
had some recent work on keyboard input event so this issue may be moot once those changes land in Bevy.Request
Does anybody have a workaround in the meantime?
winit
andbevy
may update to include all of the changes mentioned above, but has anybody seen a way of handling textbox input?Workaround
For anybody curious my workarounds are:
winit
changes land in Bevy I will update this thread with a new status and updated example(s).Beta Was this translation helpful? Give feedback.
All reactions