Commit 606c02b8 authored by David Schnur's avatar David Schnur

Tiny optimization; don't set info.y twice.

parent bceb4bfc
......@@ -314,15 +314,13 @@ browser, but needs to redraw with canvas text when exporting as an image.
var info = this.getTextInfo(layer, text, font, angle);
info.x = x;
info.y = y;
// Mark the text for inclusion in the next render pass
info.active = true;
// Save horizontal alignment for later; we'll apply it per-line
info.x = x;
info.halign = halign;
// Tweak the initial y-position to match vertical alignment
......@@ -331,6 +329,8 @@ browser, but needs to redraw with canvas text when exporting as an image.
info.y = y - info.height / 2;
} else if (valign == "bottom") {
info.y = y - info.height;
} else {
info.y = y;
}
};
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment