Skip to content

Commit 86a908b

Browse files
committed
Merge pull request #552 from fred-wang/issue489-svg
Issue #489 svg. Thanks! I hadn't gotten to it yet.
2 parents 0e92b24 + 492738c commit 86a908b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

unpacked/jax/output/SVG/jax.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1355,7 +1355,7 @@
13551355
// Handle large operator centering
13561356
//
13571357
if (values.largeop) {
1358-
svg.y = (svg.h - svg.d)/2/scale - SVG.TeX.axis_height;
1358+
svg.y = SVG.TeX.axis_height - (svg.h - svg.d)/2/scale;
13591359
if (svg.r > svg.w) {svg.ic = svg.r - svg.w; svg.w = svg.r}
13601360
}
13611361
//
@@ -1770,7 +1770,7 @@
17701770
if (boxes[i].w > WW) {WW = boxes[i].w}
17711771
}}
17721772
var t = SVG.TeX.rule_thickness;
1773-
var base = boxes[this.base] || {w:0, h:0, d:0, H:0, D:0, l:0, r:0, scale:scale};
1773+
var base = boxes[this.base] || {w:0, h:0, d:0, H:0, D:0, l:0, r:0, y:0, scale:scale};
17741774
var x, y, z1, z2, z3, dw, k, delta = 0;
17751775
if (base.ic) {delta = 1.3*base.ic + .05} // adjust faked IC to be more in line with expeted results
17761776
for (i = 0, m = this.data.length; i < m; i++) {
@@ -1796,7 +1796,7 @@
17961796
k = Math.max(z1,z2-Math.max(0,box.d));
17971797
}
17981798
k = Math.max(k,1500/SVG.em);
1799-
x += delta/2; y = base.h + box.d + k;
1799+
x += delta/2; y = base.y + base.h + box.d + k;
18001800
box.h += z3; if (box.h > box.H) {box.H = box.h}
18011801
} else if (i == this.under) {
18021802
if (accent) {
@@ -1807,7 +1807,7 @@
18071807
k = Math.max(z1,z2-box.h);
18081808
}
18091809
k = Math.max(k,1500/SVG.em);
1810-
x -= delta/2; y = -(base.d + box.h + k);
1810+
x -= delta/2; y = base.y -(base.d + box.h + k);
18111811
box.d += z3; if (box.d > box.D) {box.D = box.d}
18121812
}
18131813
svg.Add(box,x,y);

0 commit comments

Comments
 (0)