mirror of
https://github.com/atom/atom.git
synced 2026-02-15 00:55:14 -05:00
Store line endings on a per-line basis in Buffer
The line ending for each line is recorded and reused when lines are modified or inserted. Closes #166
This commit is contained in:
@@ -1076,8 +1076,11 @@ class Editor extends View
|
||||
position += token.value.length
|
||||
|
||||
popScope() while scopeStack.length > 0
|
||||
if not @mini and invisibles?.eol
|
||||
line.push("<span class='invisible'>#{invisibles.eol}</span>")
|
||||
if invisibles and not @mini
|
||||
if invisibles.cr and screenLine.lineEnding is '\r\n'
|
||||
line.push("<span class='invisible'>#{invisibles.cr}</span>")
|
||||
if invisibles.eol
|
||||
line.push("<span class='invisible'>#{invisibles.eol}</span>")
|
||||
|
||||
line.push('</pre>')
|
||||
line.join('')
|
||||
|
||||
Reference in New Issue
Block a user