"wrap_width_style": "min", "draw_centered": true
cause the text column to widen as longer lines are inserted.
#5036
Labels
Description of the bug
With
"word_wrap"
enabled,"wrap_width_style"
set to"min"
and"draw_centered"
enabled, the centered column of text is only as wide as the widest visual line of the text. This causes that inserting a line visually wider than other lines shifts all lines to the left.The widening of the column is annoying and I was told by bschaaf on Discord that
"wrap_width_style": "min"
is supposed to cause that lines wrap at the minimum of"wrap_width"
and the width of the view.A demonstration of it (not in safe mode, but it looks almost the same there):
Nahravka_obrazovky_z_8.11.2021_154934.mp4
Steps to reproduce
Start Sublime Text in safe mode.
Set these settings:
(The optional settings aren't needed to reproduce the bug itself; they are there to more closely reproduce the behavior in the video demonstration.)
An empty buffer shall have the caret in the middle.
Insert a short line.
Insert a wider line. It shall shift the first (shorter) line to the left because the centred text column widens. If any line visually wider than all other lines is inserted, it widens the centred column, so it shifts all lines to the left.
Expected behavior
With
"word_wrap"
enabled,"wrap_width_style"
set to"min"
and"draw_centered"
enabled, the width of the centred column of text should be always the minimum of"wrap_width"
and the width of the view.Actual behavior
With these settings, the width of the centred column of text is only as wide as the widest visual line.
Sublime Text build number
4121
Operating system & version
Manjaro 21.1.6-1
(Linux) Desktop environment and/or window manager
Plasma 5.22.5 on X11
Additional information
No response
OpenGL context information
No response
The text was updated successfully, but these errors were encountered: