diff --git a/GutterLayer.js b/GutterLayer.js index cddac987..c283bfa8 100644 --- a/GutterLayer.js +++ b/GutterLayer.js @@ -8,7 +8,7 @@ function GutterLayer(parentEl) GutterLayer.prototype.update = function(config) { var html = []; - for (var i=config.firstRow; i", diff --git a/VirtualRenderer.js b/VirtualRenderer.js index fdc6967f..0ff63a21 100644 --- a/VirtualRenderer.js +++ b/VirtualRenderer.js @@ -88,7 +88,7 @@ VirtualRenderer.prototype.draw = function() var lineCount = Math.ceil(minHeight / this.lineHeight); var firstRow = Math.round((this.scrollTop - offset) / this.lineHeight); - var lastRow = Math.min(lines.length, firstRow+lineCount); + var lastRow = Math.min(lines.length, firstRow+lineCount)-1; var layerConfig = this.layerConfig = { width: longestLine, @@ -97,7 +97,7 @@ VirtualRenderer.prototype.draw = function() lineHeight: this.lineHeight, characterWidth: this.characterWidth }; - + for (var i=0; i < this.layers.length; i++) { var layer = this.layers[i];