-
-
Notifications
You must be signed in to change notification settings - Fork 3
use screen line instead of logical line #16
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
Conversation
|
Thank you for the PR! This is close, but still doesn't quite behave properly. Create a file like this: Then |
|
it works fine for me: 20250128-122216-485171530.mp4maybe the behavior you saw is related to 20250128-122648-470074110.mp4if this is the case, maybe we should put: at function start and put: at function end |
|
I do not use smoothscroll. Here is how it looks for me on the current Screen.Recording.2025-01-28.140921.mp4And here is how it look with the changes in this PR: Screen.Recording.2025-01-28.141750.online-video-cutter.com.mp4HOWEVER, notice that after I zoom in, the problem goes away. So I'm not 100% sure how to trigger this, but somehow through resizing my terminal window, splitting inside vim, zooming in and out, etc. I am able to consistently (but not repeatably) encounter this behavior where it snaps line 17 to the top. Apologies, I don't know how to record with the keystrokes. Any tips on this would be appreciated. Furthermore, it your cursor is in the middle of line 12, centering will move the cursor to line 11, which is not desirable. This behavior exists in both versions, so maybe it can be a separate bug. |
|
I didn't express myself clearly. What I meant is that you need to The software displaying my key presses is Screenkey.
As for the this issue, it seems to be caused by |
|
Ah, I see now. Yes, you are right. I was able to replicate the weird buggy behavior, then toggle smoothscroll on and off and it always worked correctly with smoothscroll on and incorrectly with smoothscroll off. I will add a smoothscroll setting in another commit (see #17) and accept this PR. I also created a separate issue for the line changing thing (#18). |
use screen line instead of logical line to calculate offset
may fix #13 #14