-
-
Notifications
You must be signed in to change notification settings - Fork 204
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
Add vim-like page scrolling #1072
Conversation
Ooh, I would love this feature as well! There is one thing that I'm a bit worried about when adding this, and it's something I also mentioned in my feature request. In Vim, you don't really delete things by accident by using |
Dang, the rest of the feature request makes more sense now! A suggestion: what if the default key to delete were changed from EDIT: I just saw that |
I know I suggested changing the key in the feature request as well but in hindsight, I'm not a big fan of that. I think programs should keep working the same for long time users of the software. Of course if hrkfdn thinks it's best to change the keymap, this issue of |
Also quickly wanted to say you forgot to format I think 😉 The workflow would catch this anyway but thought I'd quickly let you know. In Rust, you can use |
True, yeah that sounds like a diplomatic solution. If @hrkfdn would prefer to change the map in a future major release, the groundwork and some good suggestions are here. When I get a bit of time, I'll remove the default keymaps this adds and propose an addition to the readme to make this feature a bit more discoverable 👍
Haha yep! I had forgotten to enable autoformatting on write for rs files. I didn't know about |
Alrighty, new default keybinds removed and added move variants to the parser. I'll think about the readme change for a bit more and update this soon |
When updating the readme, I thought of a slightly better interface for these commands, I think I'll try implement a |
Hey there, sorry for the delay. Thanks for the PR and the valuable discussion. FYI: I agree w/ both of you: while the existing binding isn't perfect we probably shouldn't break it. Merging the PR in a second :) |
First pass at implementing page scrolling for list views and help views with
<C-d>/<C-u>
to scroll down/up by half a page and<C-f>/<C-b>
to scroll down/up by a full page.Addresses the first part of issue #959.
I've confirmed this build works with this in my
.config/ncspot/config.toml
:I've been using NCSpot for a while, and this is a feature I personally wanted as well. I was inspired to learn enough Rust so that I could make this contribution! Very open to feedback, let me know if adding this feature to one of the keybinds tables in the
README.md
would be appreciated.