-
Notifications
You must be signed in to change notification settings - Fork 283
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
Smooth scrolling instead of line scrolling? #1408
Comments
Update: this may just be a function of how scroll amount and momentum is (not) implemented. I noted on further playing that Oni does support this, and in fact if you scroll using a trackpad or mouse it will sometimes end up on half lines: …but it doesn't scroll there smoothly, and as a result it's not actually possible to scroll precisely within a document. |
@szbergeron has been working on smooth scrolling for Revery in revery-ui/revery#766. Once that's in it should be straight forward to support here as well. |
Hi @chriskrycho, what platform are you on again? Currently I only have sdl support for smooth scrolling stood up for Wayland on Linux, but will put some more time into plumbing that out x-Plat after libscroll is integrated |
Thanks for the quick response! I'm on macOS – meant to include that in the writeup last night. 🤦♂ |
@chriskrycho I don't personally have a macos machine to test on but I can try getting some experimental patches up if you're willing to test them out :) |
Would be delighted to! |
Copied from discord: if someone could try inserting prints near each of those and figuring out which actually handles both mouse wheel and touchpad pan events that would be fantastic, I should be able to mostly figure it out from there
(these are in esy-sdl2) If you want some help setting up an env for testing any of that lemme know, should hopefully be able to figure it out from there (just interpreting NSEvents into PanEvents and bubbling them up) |
I'll try to hop on Discord at some point and chat through it! I'm busy most of today and tomorrow (including the evenings) but should have some time on Friday! |
Sounds good, see you there |
Hasn't worked out, but will try to make this happen sometime next week. |
@chriskrycho no worries, I'll be a little bit on the libscroll integration anyway so no rush from that end lol |
Are there any updates on this? It is the only issue that keeps me from moving from SublimeText to the Onivim. It would be amazing to have at least to have an option to configure the scroll step to make it smaller. Looks like a smooth scroll is implemented, it does not look line-based anymore. |
Currently, Oni's scrolling is line-based (as well as lacking momentum). Native-stack text editor UIs normally allow scrolling smoothly throughout the view, including such that the scroll can leave the view mid-way through lines.
VS Code:
Sublime Text:
I know this is not the usual for Vim, seeing as it's not the norm for terminal emulators, but I come to Oni as someone who finds terminal-driven editors off-putting but likes the idea of rich modal editing appealing.
The text was updated successfully, but these errors were encountered: