From 1bdf45f7d6fa528ec20c2f408866866d5b6139d8 Mon Sep 17 00:00:00 2001 From: Ben Ogle Date: Wed, 11 Jun 2014 17:28:12 -0700 Subject: [PATCH] Fix gutter width When you had a 1000 line file and you fold everything into 10 lines, it would make the gutter width only large enough for the 10 lines, so line 999 wouldnt properly fit in the gutter. Refs #2423 --- src/editor-component.coffee | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/editor-component.coffee b/src/editor-component.coffee index edca56a65..d278905ac 100644 --- a/src/editor-component.coffee +++ b/src/editor-component.coffee @@ -41,7 +41,7 @@ EditorComponent = React.createClass render: -> {focused, fontSize, lineHeight, fontFamily, showIndentGuide, showInvisibles, visible} = @state {editor, cursorBlinkPeriod, cursorBlinkResumeDelay} = @props - maxLineNumberDigits = editor.getScreenLineCount().toString().length + maxLineNumberDigits = editor.getLineCount().toString().length invisibles = if showInvisibles then @state.invisibles else {} hasSelection = editor.getSelection()? and !editor.getSelection().isEmpty()