www

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit a0e0567028c958dc57c7f83f4141fad0119d9b1e
parent cb207408619bf8ef3feaf40bffcbbc6a82964f02
Author: Davide P. Cervone <dpvc@union.edu>
Date:   Thu, 21 Mar 2013 09:12:10 -0400

Merge remote-tracking branch 'fred/issue366' into develop

Resolves issue #366.

Diffstat:
Munpacked/jax/output/HTML-CSS/jax.js | 7+++++--
1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/unpacked/jax/output/HTML-CSS/jax.js b/unpacked/jax/output/HTML-CSS/jax.js @@ -298,6 +298,9 @@ webFontDefault: "MathJax_Blank", allowWebFonts: "otf", // assume browser can use OTF web fonts + maxStretchyParts: 1000, // limit the number of parts allowed for + // stretchy operators. See issue 366. + Config: function () { if (!this.require) {this.require = []} this.Font = FONTTEST(); @@ -1132,7 +1135,7 @@ if (H > h) { ext = this.Element("span"); this.createChar(ext,delim.ext,scale,font); var eH = ext.bbox.h + ext.bbox.d, eh = eH - .05, n, N, k = (delim.mid ? 2 : 1); - N = n = Math.ceil((H-h)/(k*eh)); + N = n = Math.min(Math.ceil((H-h)/(k*eh)), this.maxStretchyParts); if (!delim.fullExtenders) {eh = (H-h)/(k*n)} var dy = (n/(n+1))*(eH - eh); eh = eH - dy; y += dy + eh - ext.bbox.h; while (k-- > 0) { @@ -1182,7 +1185,7 @@ if (delim.min && W < w*delim.min) {W = w*delim.min} if (W > w) { var rW = rep.bbox.rw-rep.bbox.lw, rw = rW - .05, n, N, k = (delim.mid ? 2 : 1); - N = n = Math.ceil((W-w)/(k*rw)); + N = n = Math.min(Math.ceil((W-w)/(k*rw)), this.maxStretchyParts); if (!delim.fillExtenders) {rw = (W-w)/(k*n)} dx = (n/(n+1))*(rW - rw); rw = rW - dx; x -= rep.bbox.lw + dx; while (k-- > 0) {