gyscos / gyscos/cursive

[FEATURE] Allow customization of keybindings

Open
#740 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
4.8k
Forks
270
Avg merge
5d 19h
Merged PRs (30d)
2

Description

**Is your feature request related to a problem? Please describe.**
I'm currently developing wiki-tui, where I want the user to be able to configure the keybindings used in the app (that includes scrolling, changing focus, etc.). Because the current keybindings are hardcoded into the individual view implementation, it is very hard (or impossible) to be able to change them and include new ones (for example scroll 10 lines down, etc.).

**Describe the solution you'd like**
It would be nice if we could change the keybindings of individual views and if we could have access to deeper levels of some views that are currently private (for example scrolling is abstracted away and we cannot have custom scrolling actions).

**Describe alternatives you've considered**
What I'm currently doing is copying the `ScrollView` and `SelectView` codes and then implementing custom keybindings there. But that's tedious and a pain to update. I'm also wrapping views and layers to be able to change the events coming in.

**Additional context**
If you want, I would be happy to try implementing this feature (of course, first discussing design choices and what needs to be implemented in detail)!

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.