Skip to content

Commit

Permalink
🎨
Browse files Browse the repository at this point in the history
  • Loading branch information
as-cii committed Oct 15, 2015
1 parent 4818d47 commit 43229a1
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions src/display-buffer.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ class DisplayBuffer extends Model
if defaultCharWidth isnt @defaultCharWidth or doubleWidthCharWidth isnt @doubleWidthCharWidth
@defaultCharWidth = defaultCharWidth
@doubleWidthCharWidth = doubleWidthCharWidth
@updateWrappedScreenLines() if @isSoftWrapped()
@updateWrappedScreenLines() if @isSoftWrapped() and @getWidth()?
defaultCharWidth

getCursorWidth: -> 1
Expand Down Expand Up @@ -265,14 +265,8 @@ class DisplayBuffer extends Model
else
@getEditorWidthInChars()

getMaxLengthPerLine: ->
if @configSettings.softWrapAtPreferredLineLength
Math.min(@getEditorWidthInChars(), @configSettings.preferredLineLength)
else
@getEditorWidthInChars()

getSoftWrapColumnForTokenizedLine: (tokenizedLine) ->
lineMaxWidth = @getMaxLengthPerLine() * @getDefaultCharWidth()
lineMaxWidth = Math.round(@getSoftWrapColumn() * @getDefaultCharWidth())
iterator = tokenizedLine.getTokenIterator()
column = 0
currentWidth = 0
Expand Down

0 comments on commit 43229a1

Please sign in to comment.