sublime_text icon indicating copy to clipboard operation
sublime_text copied to clipboard

Cursor does not position correctly at start of automatically broken line

Open rogeriodec opened this issue 3 years ago • 1 comments

Description of the bug

When I have Word Wrap enabled and a text exceeds the line character limit, the cursor does not go through the first character of the wrapped text on the line below.

Steps to reproduce

  1. Activate Word Wrap
  2. Type something until it forces the line to wrap automatically
  3. Move the cursor between the last character of the first line and the first character of the next line and you will see that it does not position itself on this first character of the next line. a

Expected behavior

The cursor should be positioned BEFORE the first character of the next line

Actual behavior

The cursor should be ignoring the first character of the next line

Sublime Text build number

4126

Operating system & version

Windows 10

(Linux) Desktop environment and/or window manager

No response

Additional information

No response

OpenGL context information

No response

rogeriodec avatar Jun 28 '22 22:06 rogeriodec

The caret is directly in front of 1 if it is rendered at the the end of line 1. As newline character is skipped (ignored aka. not handled when navigating), moving onward results in caret visually jumping from end of line 1 to column 2 on line 2.

A probably easier to follow approach was to directly render the caret in front of 1 in line 2 when it is moved after the last character of line 1.

deathaxe avatar Jul 01 '22 14:07 deathaxe

I would love to see this fixed. It's an oddity that confuses me often (you'd think I'd be used to it by now). My Christmas wish!

frithrah avatar Dec 14 '23 22:12 frithrah