Closed dennisorlando closed 1 year ago
there's the "lapce" text editor written in rust that appears to be using the "druid" library
there's the "lapce" text editor written in rust that appears to be using the "druid" library
I think lapce is migrating to a custom framework called Floem, which is based on the Xilem architecture.
I think the callback you're looking for is on_keyboard_char
-- this gives you the Unicode codepoint of which key was pressed, for the purpose of text entry.
on_key_up
and on_key_down
are aimed at things like games, where you want to know when a specific keyboard key was pressed/released, so these shouldn't be used for text entry.
I think the callback you're looking for is
on_keyboard_char
-- this gives you the Unicode codepoint of which key was pressed, for the purpose of text entry.
on_key_up
andon_key_down
are aimed at things like games, where you want to know when a specific keyboard key was pressed/released, so these shouldn't be used for text entry.
oh, there it is! Works like a charm, thanks
Hi, I'm trying to get a simple text editor working but it appears to be very challenging given that VirtualKeyCode doesn't include all the characters and that the "KeyScancode to Ascii code" problem appears to be a problem which there are no libraries for (I literally can't find anything on the internet other than open issues and hardcoded maps). It appears that this issue also propagates to winit and glutin; is there any way to solve this?
Possible things that might be worth looking into: