commit 267a9a90eb81904402d8126754bc01444be4ef97
parent 2c3a5f0b79c7b160af41734fd5b290327ad63fba
Author: Davide P. Cervone <dpvc@union.edu>
Date: Wed, 14 May 2014 09:30:05 -0400
Use width and height attributes rather than styles.
Diffstat:
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/unpacked/jax/output/SVG/jax.js b/unpacked/jax/output/SVG/jax.js
@@ -2009,8 +2009,8 @@
//
var l = Math.max(-svg.l,0), r = Math.max(svg.r-svg.w,0);
var style = svg.element.style;
- style.width = SVG.Ex(l+svg.w+r);
- style.height = SVG.Ex(svg.H+svg.D+2*SVG.em);
+ svg.element.setAttribute("width",SVG.Ex(l+svg.w+r));
+ svg.element.setAttribute("height",SVG.Ex(svg.H+svg.D+2*SVG.em));
style.verticalAlign = SVG.Ex(-svg.D-3*SVG.em); // remove 2 extra pixels added below plus padding
style.marginLeft = SVG.Ex(-l); style.marginRight = SVG.Ex(-r);
svg.element.setAttribute("viewBox",(-l)+" "+(-svg.H-SVG.em)+" "+(l+svg.w+r)+" "+(svg.H+svg.D+2*SVG.em));