From b1647c98e7ba7d1c895b224baf2624088913612a Mon Sep 17 00:00:00 2001 From: "Davide P. Cervone" Date: Sat, 12 Sep 2015 07:30:54 -0400 Subject: [PATCH] Make sure CommonHTML output is marked by isMathJax --- unpacked/jax/output/CommonHTML/jax.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/unpacked/jax/output/CommonHTML/jax.js b/unpacked/jax/output/CommonHTML/jax.js index 65fa68910..f3d070fba 100644 --- a/unpacked/jax/output/CommonHTML/jax.js +++ b/unpacked/jax/output/CommonHTML/jax.js @@ -323,6 +323,7 @@ Element: function (type,def,content) { if (type.substr(0,4) === "mjx-") { if (!def) def = {}; + if (def.isMathJax == null) def.isMathJax = true; if (def.className) def.className = type+" "+def.className; else def.className = type; } return this.HTMLElement("span",def,content); @@ -379,7 +380,7 @@ // // Zoom box requires an outer container to get the positioning right. // - var NODE = CHTML.Element("mjx-chtml",{className:"MJXc-display"}); + var NODE = CHTML.Element("mjx-chtml",{className:"MJXc-display",isMathJax:false}); NODE.appendChild(node); node = NODE; } if (HUB.Browser.noContextMenu) { @@ -579,7 +580,7 @@ // Re-render at larger size // this.getMetrics(jax); - var node = CHTML.addElement(span,"mjx-chtml",{style:{"font-size":Math.floor(CHTML.scale*100)+"%"}}); + var node = CHTML.addElement(span,"mjx-chtml",{style:{"font-size":Math.floor(CHTML.scale*100)+"%"},isMathJax:false}); this.idPostfix = "-zoom"; jax.root.toCommonHTML(node); this.idPostfix = ""; // // Adjust margins to prevent overlaps at the edges