Make sure these extensions pas on ALL arguments to the routines they override. (Needed for fix to toHTML to allow measurements to be grouped.)
This commit is contained in:
parent
f21589ea9a
commit
8c9fc2122b
|
@ -66,7 +66,7 @@ MathJax.Hub.Register.StartupHook("HTML-CSS Jax Ready",function () {
|
|||
TRANSLATE = HTMLCSS.Translate;
|
||||
HTMLCSS.Augment({
|
||||
Translate: function (script,state) {
|
||||
TRANSLATE.call(this,script,state);
|
||||
TRANSLATE.apply(this,arguments);
|
||||
if (script.MathJax.elementJax.HTMLCSS.display) {
|
||||
var next = script.nextSibling;
|
||||
if (!next || next.className !== "MathJax_MSIE_Separator") {
|
||||
|
|
|
@ -154,7 +154,7 @@
|
|||
span = this.HTMLcreateSpan(span);
|
||||
span.bbox = data.data[0].toHTML(span).bbox;
|
||||
} else {
|
||||
span = MATH.call(this,span,node);
|
||||
span = MATH.apply(this,arguments);
|
||||
}
|
||||
return span;
|
||||
}
|
||||
|
@ -166,7 +166,7 @@
|
|||
//
|
||||
MML.merror.Augment({
|
||||
toHTML: function (span) {
|
||||
if (!this.isError) {return MERROR.call(this,span)}
|
||||
if (!this.isError) {return MERROR.apply(this,arguments)}
|
||||
span = this.HTMLcreateSpan(span); span.className = "noError"
|
||||
if (this.multiLine) {span.style.display = "inline-block"}
|
||||
var text = this.data[0].data[0].data.join("").split(/\n/);
|
||||
|
@ -218,7 +218,7 @@
|
|||
toSVG: function (span,node) {
|
||||
var data = this.data[0];
|
||||
if (data && data.data[0] && data.data[0].isError)
|
||||
{span = data.data[0].toSVG(span)} else {span = MATH.call(this,span,node)}
|
||||
{span = data.data[0].toSVG(span)} else {span = MATH.apply(this,arguments)}
|
||||
return span;
|
||||
}
|
||||
});
|
||||
|
@ -229,7 +229,7 @@
|
|||
//
|
||||
MML.merror.Augment({
|
||||
toSVG: function (span) {
|
||||
if (!this.isError || this.Parent().type !== "math") {return MERROR.call(this,span)}
|
||||
if (!this.isError || this.Parent().type !== "math") {return MERROR.apply(this,arguments)}
|
||||
span = HTML.addElement(span,"span",{className: "noError", isMathJax:true});
|
||||
if (this.multiLine) {span.style.display = "inline-block"}
|
||||
var text = this.data[0].data[0].data.join("").split(/\n/);
|
||||
|
@ -267,7 +267,7 @@
|
|||
toNativeMML: function (span) {
|
||||
var data = this.data[0];
|
||||
if (data && data.data[0] && data.data[0].isError)
|
||||
{span = data.data[0].toNativeMML(span)} else {span = MATH.call(this,span)}
|
||||
{span = data.data[0].toNativeMML(span)} else {span = MATH.apply(this,arguments)}
|
||||
return span;
|
||||
}
|
||||
});
|
||||
|
@ -278,7 +278,7 @@
|
|||
//
|
||||
MML.merror.Augment({
|
||||
toNativeMML: function (span) {
|
||||
if (!this.isError) {return MERROR.call(this,span)}
|
||||
if (!this.isError) {return MERROR.apply(this,arguments)}
|
||||
span = span.appendChild(document.createElement("span"));
|
||||
var text = this.data[0].data[0].data.join("").split(/\n/);
|
||||
for (var i = 0, m = text.length; i < m; i++) {
|
||||
|
@ -328,7 +328,7 @@
|
|||
//
|
||||
MML.merror.Augment({
|
||||
toCommonHTML: function (span) {
|
||||
if (!this.isError) {return MERROR.call(this,span)}
|
||||
if (!this.isError) {return MERROR.apply(this,arguments)}
|
||||
span = this.CHTMLcreateSpan(span); span.className = "noError"
|
||||
if (this.multiLine) {span.style.display = "inline-block"}
|
||||
var text = this.data[0].data[0].data.join("").split(/\n/);
|
||||
|
|
|
@ -124,7 +124,7 @@ MathJax.Hub.Register.StartupHook("HTML-CSS Jax Ready",function () {
|
|||
var GETVARIANT = MML.mbase.prototype.HTMLgetVariant;
|
||||
MML.mbase.Augment({
|
||||
HTMLgetVariant: function () {
|
||||
var variant = GETVARIANT.call(this);
|
||||
var variant = GETVARIANT.apply(this,arguments);
|
||||
if (variant.unicode) {delete variant.unicode; delete variant.FONTS} // clear font cache in case of restart
|
||||
if (!this.unicode) {return variant}
|
||||
variant.unicode = true;
|
||||
|
|
Loading…
Reference in New Issue
Block a user