commit f6293beea624b0439cde560050bee06ddc1c0a36
parent 142857afa2ca5854f72c3955f1676660c79b2e72
Author: Davide P. Cervone <dpvc@union.edu>
Date: Thu, 4 Dec 2014 16:56:35 -0500
Add the SVG transform for flipping characters AFTER we have added colors and borders (since they can alter the svg.element, moving it lower in the chain and even removing it). Resolves issue #930.
Diffstat:
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/unpacked/jax/output/SVG/jax.js b/unpacked/jax/output/SVG/jax.js
@@ -2030,12 +2030,13 @@
// Put content in a <g> with defaults and matrix that flips y axis.
// Put that in an <svg> with xlink defined.
//
- var box = BBOX.G({
+ var box = BBOX.G(); box.Add(this.data[0].toSVG(),0,0,true); box.Clean();
+ this.SVGhandleColor(box);
+ SVG.Element(box.element,{
stroke:"black", fill:"black", "stroke-width":0,
transform: "matrix(1 0 0 -1 0 0)"
- }).With({removeable: false});
- box.Add(this.data[0].toSVG(),0,0,true); box.Clean();
- this.SVGhandleColor(box);
+ });
+ box.removeable = false;
var svg = this.SVG();
svg.element.setAttribute("xmlns:xlink",XLINKNS);
if (CONFIG.useFontCache && !CONFIG.useGlobalCache)