mirror of
https://github.com/atom/atom.git
synced 2026-02-10 14:45:11 -05:00
Make lines extend across the entire width of the scroller
This ensures line decorations render properly, even when the content is narrower than the editor.
This commit is contained in:
committed by
Antonio Scandurra
parent
5c7208751f
commit
1427dbf540
@@ -1496,7 +1496,10 @@ class TextEditorComponent {
|
||||
if (this.getModel().isSoftWrapped()) {
|
||||
return this.getClientWidth() - this.getGutterContainerWidth()
|
||||
} else {
|
||||
return Math.round(this.measurements.longestLineWidth + this.measurements.baseCharacterWidth)
|
||||
return Math.max(
|
||||
Math.round(this.measurements.longestLineWidth + this.measurements.baseCharacterWidth),
|
||||
this.measurements.scrollerWidth - this.getGutterContainerWidth()
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user