Skip to content

Commit 5921c8c

Browse files
committed
Make IE9 and IE10 use SVG for menclose rather than SVG (when in a document mode that supports it). Resolves issue #324.
1 parent e7b2972 commit 5921c8c

File tree

2 files changed

+14
-9
lines changed

2 files changed

+14
-9
lines changed

jax/output/HTML-CSS/autoload/menclose.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

unpacked/jax/output/HTML-CSS/autoload/menclose.js

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -279,14 +279,19 @@ MathJax.Hub.Register.StartupHook("HTML-CSS Jax Ready",function () {
279279

280280
MathJax.Hub.Browser.Select({
281281
MSIE: function (browser) {
282-
MML.menclose.Augment({HTMLpx: function (n,d) {return (n*HTMLCSS.em+(d||0))+"px"}});
283-
HTMLCSS.useVML = true;
284-
if (!document.namespaces[vmlns]) {
285-
if (document.documentMode && document.documentMode >= 8) {
286-
document.namespaces.add(vmlns,VMLNS,"#default#VML");
287-
} else {
288-
document.namespaces.add(vmlns,VMLNS);
289-
document.createStyleSheet().addRule(vmlns+"\\: *","{behavior: url(#default#VML)}");
282+
//
283+
// IE8 and below doesn't have SVG, so use VML
284+
//
285+
if ((document.documentMode||0) < 9) {
286+
MML.menclose.Augment({HTMLpx: function (n,d) {return (n*HTMLCSS.em+(d||0))+"px"}});
287+
HTMLCSS.useVML = true;
288+
if (!document.namespaces[vmlns]) {
289+
if (document.documentMode && document.documentMode === 8) {
290+
document.namespaces.add(vmlns,VMLNS,"#default#VML");
291+
} else {
292+
document.namespaces.add(vmlns,VMLNS);
293+
document.createStyleSheet().addRule(vmlns+"\\: *","{behavior: url(#default#VML)}");
294+
}
290295
}
291296
}
292297
}

0 commit comments

Comments
 (0)