logoalt Hacker News

hwhshstoday at 12:40 PM3 repliesview on HN

Why not a vim plugin


Replies

cassepipetoday at 1:15 PM

> Note that the Ki keybindings cannot be simply implemented in Vim/Helix via key- remapping, due to the lack of the concept of Selection Mode, and implementing that requires major architectural changes in the core.

show 1 reply
0ta2x6j3today at 2:31 PM

It's funny you mention that. I am currently working on a neovim plugin which implements the ki-editor keymap.

https://codeberg.org/alicealysia/ki-bindings.nvim

Unfortunately however, there's some shortcomings of neovim which make its control scheme impossible (at least not without some workarounds)

One of the biggest is ki's momentary layers feature.

Ki uses the kitty keyboard protocol to detect when a key is being held and when it is released in order to allow for unique actions when multiple keys are pressed simultaneously, and this functionality is a big part of what makes it so ergonomic.

For example, tapping c will copy the currently highlighted text, but pressing c and k simultaneously will duplicate the currently selected text to a new line below the current line.

While I'm currently chipping away at a pull request to introduce similar functionality to neovim itself, in the meantime, I'm needing to work around the issue by making a lot of concessions.