You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There are two important settings in VS Code that control line wrapping.
editor.wrappingColumn (300 by default)
and editor.wordWrap (false by default)
Examples (with explanations):
wordWrap
wrappingColumn
Behaviour
false
N > 0
Lines will wrap at N
false
0
Lines will wrap at viewport_column
false
-1
Lines will never wrap.
true
N > 0
Lines will wrap at min(viewport_column, N)
true
0
Lines will wrap at viewport_column
true
-1
Lines will never wrap.
The fact that wrappingColumn is the primary setting and that we wrap at 300 by default is causing a lot of pain.
For example, the Toggle Word Wrap action toggles wordWrap: false | true in user settings. But if wrappingColumn is also configured, the action becomes a no-op.
The proposal
The proposal is to focus on the most important use-cases and to make wordWrap the primary setting.
To prevent unexpected behaviours for folks already using wrappingColumn, it will be completely ignored (deprecated) and a new setting editor.wordWrapColumn will take part of its attributes:
editor.wordWrap
Behaviour
"off"
Lines will never wrap.
"on"
Lines will wrap at viewport
"wordWrapColumn"
Lines will wrap at editor.wordWrapColumn
"bounded"
Lines will wrap at min(viewport, editor.wordWrapColumn)
The defaults change to => wordWrap: "off", wordWrapColumn: 80
The Toggle Word Wrap action should toggle wordWrap: "on" | "off" in user settings. There is a separate issue #20675, tracking that the Toggle Word Wrap should not persist to user settings or do so in a per-buffer way.
The text was updated successfully, but these errors were encountered:
The problem
There are two important settings in VS Code that control line wrapping.
editor.wrappingColumn
(300 by default)editor.wordWrap
(false by default)Examples (with explanations):
wordWrap
wrappingColumn
N
viewport_column
min(viewport_column, N)
viewport_column
The fact that
wrappingColumn
is the primary setting and that we wrap at300
by default is causing a lot of pain.For example, the Toggle Word Wrap action toggles
wordWrap: false | true
in user settings. But ifwrappingColumn
is also configured, the action becomes a no-op.The proposal
The proposal is to focus on the most important use-cases and to make
wordWrap
the primary setting.To prevent unexpected behaviours for folks already using
wrappingColumn
, it will be completely ignored (deprecated) and a new settingeditor.wordWrapColumn
will take part of its attributes:editor.wordWrap
editor.wordWrapColumn
min(
viewport,editor.wordWrapColumn)
The defaults change to =>
wordWrap: "off"
,wordWrapColumn: 80
The Toggle Word Wrap action should toggle
wordWrap: "on" | "off"
in user settings. There is a separate issue #20675, tracking that the Toggle Word Wrap should not persist to user settings or do so in a per-buffer way.The text was updated successfully, but these errors were encountered: