Vintage icon indicating copy to clipboard operation
Vintage copied to clipboard

Relative line number motions do not work correctly when word wrap is enabled

Open jamessimas opened this issue 1 week ago • 1 comments

Description of the bug

With the following conditions...

  • Vintage mode enabled
  • Relative line numbers enabled ("relative_line_numbers": true)
  • Word Wrap enabled

...relative line number motions do not work correctly. Rather than taking me N lines up/down, they take me N wrapped-lines up/down. (See screenshot for exact behavior description. It's hard to describe in words.)

This happens every time lines wrap and there is no workaround that I am aware of.

This works as expected in both VIM 9.0 and NeoVIM v0.10.1.

Image

Steps to reproduce

  1. Open a plain text which has long lines file in Sublime Text
  2. Enable Vintage mode
  3. Enable relative line numbers ("relative_line_numbers": true)
  4. Enable Word Wrap
  5. Attempt to use relative line motions (e.g., 2j, 4k, etc.) to move. Notice that they do not work as expected.

Expected behavior

When using relative line motions to navigate when Word Wrap is enabled, the motions will take me to the correct line.

Actual behavior

When using relative line motions to navigate when Word Wrap is enabled, the line motions take me to the wrong line every time.

Sublime Text build number

4180

Operating system & version

macOS 14.6.1

(Linux) Desktop environment and/or window manager

No response

Additional information

No response

OpenGL context information

No response

jamessimas avatar Feb 11 '25 17:02 jamessimas