Browse Source

Optimization: don't scale when parameter is 1.0

notmasteryet 13 years ago
parent
commit
cc9035438a
  1. 3
      src/canvas.js

3
src/canvas.js

@ -728,7 +728,8 @@ var CanvasGraphics = (function CanvasGraphicsClosure() {
if (textSelection) if (textSelection)
text.geom = this.getTextGeometry(); text.geom = this.getTextGeometry();
ctx.scale(fontSizeScale, fontSizeScale); if (fontSizeScale != 1.0)
ctx.scale(fontSizeScale, fontSizeScale);
var x = 0; var x = 0;
for (var i = 0; i < glyphsLength; ++i) { for (var i = 0; i < glyphsLength; ++i) {

Loading…
Cancel
Save