Skip to content

Commit

Permalink
Make sure gutter does not confuse line wrapping measurements
Browse files Browse the repository at this point in the history
  • Loading branch information
marijnh committed Nov 7, 2011
1 parent 0fd987a commit a5aea8a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/codemirror.js
Expand Up @@ -879,7 +879,7 @@ var CodeMirror = (function() {

if (!updates.length) return;
var th = textHeight();
lineDiv.style.display = "none";
lineDiv.style.display = gutter.style.display = "none";
// If more than 30% of the screen needs update, just do a full
// redraw (which is quicker than patching)
if (changedLines > (visible.to - visible.from) * .3)
Expand Down Expand Up @@ -925,8 +925,8 @@ var CodeMirror = (function() {
lineSpace.style.width = code.style.width = "";
}
}
gutter.style.display = "";
if (different || gutterDirty) updateGutter();

updateCursor();
}

Expand Down

0 comments on commit a5aea8a

Please sign in to comment.