Make SVG output not include emtpy attributes for unknown characters. Issue #898 and mathjax/MathJax-node#6.
This commit is contained in:
parent
56c2da92d5
commit
e090b7821a
|
@ -1006,6 +1006,8 @@
|
||||||
type: "text", removeable: false,
|
type: "text", removeable: false,
|
||||||
Init: function (scale,text,def) {
|
Init: function (scale,text,def) {
|
||||||
if (!def) {def = {}}; def.stroke = "none";
|
if (!def) {def = {}}; def.stroke = "none";
|
||||||
|
if (def["font-style"] === "") delete def["font-style"];
|
||||||
|
if (def["font-weight"] === "") delete def["font-weight"];
|
||||||
this.SUPER(arguments).Init.call(this,def);
|
this.SUPER(arguments).Init.call(this,def);
|
||||||
SVG.addText(this.element,text);
|
SVG.addText(this.element,text);
|
||||||
SVG.textSVG.appendChild(this.element);
|
SVG.textSVG.appendChild(this.element);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user