-
-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove backwards in insert mode is broken #113
Comments
Do you mean the DELETE key? :) |
Yes that's the one. In German, it's called the remove key. |
No, specifically because it doesn't work, it's supposed to be disabled. Well, I say disabled but really what I mean is we've disabled the key as found on ISO standard layout keyboards. What's actually happening when you enter keys which don't technically represent a normal visible character (either ANSI or UTF-8) that we're not handling the functionality of, it's really inserting a bunch of values as UTF-8 code points into the document which don't make sense, and causing whitespace to appear and the cursor to freak out. |
Can you please try this example project in the V lang repo: https://github.com/vlang/v/blob/master/examples/term.ui/event_viewer.v and provide a list of the output if you press practically every key? |
I'm not using a standard ISO layout, which is probably why it still inserts the UTF-8 bytes. That's on me, but good to know! |
It shouldn't be on you, we should be handling all layouts the same, I thought the module for term ui generalised this stuff, but it looks like we might need to do some locale handling after all. |
I'm interested to see a list of all of the keys you have, probably in text form but you'd have to adjust the example slightly to append it's output to a file and show it within the console. |
I've managed to capture the right key |
That's very helpful, thank you. That's interesting. In order to solve this issue, what I think we should really do is just have better support/understanding of different key layouts and board layouts and how to map between them. Let me go away and think of something to send you which we can use to send you to gather some data regarding your setup. |
Basically, the functionality regarding key information we're receiving from term.ui currently is not good enough. It's identified your key's code as |
Is that something I could do or that could be automated using a script? Something along the lines of 'oh you have a custom layout? Please press these keys in order to configure Lilly' |
It's something which would ask X11 or Wayland, or (Windows UI?) whatever is being used as the window manager for the current layout and we would just need to have a set of mappings for each known one. For example, if I run
Having said that, I doubt Neovim is doing something similar to this, but I have yet to do enough research and reading to check. If Neovim is doing some magical easier technique realistically we should be doing the same. This is the first time I'm trying to solve a problem such as this. |
When I try to remove the character on the right of my cursor in insert mode using the remove key, Lilly won't remove it but kind of bug out. Below I've attached a video of me using remove in Neovim and in Lilly to demonstrate what I mean.
2023-12-05_21-44-27.mp4
The text was updated successfully, but these errors were encountered: