Task of Sisyphus: Filter bogus attributes generated by Gecko (again)

This commit is contained in:
Jacques Distler 2010-04-28 11:54:56 -05:00
parent d1678ceb49
commit 86a53d1dfa
4 changed files with 34 additions and 13 deletions

View file

@ -1,4 +1,4 @@
/*
/*
* svgcanvas.js
*
* Licensed under the Apache License, Version 2
@ -1631,7 +1631,10 @@ function BatchCommand(text) {
// Namespaces have already been dealt with, so skip
if(attr.nodeName.indexOf('xmlns:') === 0) continue;
//remove bogus attributes added by Gecko
if (attr.localName == '-moz-math-font-style') continue;
// only serialize attributes we don't use internally
if (attrVal != "" &&
$.inArray(attr.localName, ['width','height','xmlns','x','y','viewBox','id','overflow']) == -1)