[vim/vim] scroll: 'smoothscroll' position is lost when using "|" (PR #20890)

1 view
Skip to first unread message

h_east

unread,
3:59 AM (18 hours ago) 3:59 AM
to vim/vim, Subscribed
Problem:  With 'smoothscroll' the scroll position in a long line is lost when
          moving to a column with "|".
Solution: Adjust the skipped columns for the column the cursor ends up in,
          not for column zero.

related: #20885


There is no issue for this, it was found while auditing the places that
reset w_skipcol, after patch 9.2.0881.

With 'smoothscroll' and a line that is longer than the window, ":norm 240|"
scrolled the window back to the start of the line. "|" moves the cursor to
column zero first and only then to the wanted column, and beginline()
adjusts the skipped columns before that second step.

The screen dumps of Test_smooth_long_scrolloff_* are updated. They were
made with the old behaviour, where resetting the skipped columns and
adjusting them again caused a full redraw that cleared the command line.
The text, the cursor position and the ruler are unchanged; only
":norm j721|" now stays on the command line, as it does after any other Ex
command.


You can view, comment on, or merge this pull request online at:

  https://github.com/vim/vim/pull/20890

Commit Summary

  • 65b3c9b scroll: 'smoothscroll' position is lost when using "|"

File Changes

(16 files)

Patch Links:


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/20890@github.com>

Christian Brabandt

unread,
2:13 PM (8 hours ago) 2:13 PM
to vim/vim, Subscribed
chrisbra left a comment (vim/vim#20890)

thanks


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/20890/c5146084191@github.com>

Reply all
Reply to author
Forward
0 new messages