Only set opacity and visibility when they differ from the defaults.

This commit is contained in:
Jürg Lehni 2012-11-07 01:02:28 -08:00
parent 01342fa073
commit 0e22430993

View file

@ -353,11 +353,11 @@ new function() {
}
});
if (item._opacity != null)
if (item._opacity != null && item._opacity < 1)
attrs.opacity = item._opacity;
if (item._visibility != null)
attrs._visibility = item._visibility ? 'visible' : 'hidden';
if (item._visibility != null && !item._visibility)
attrs.visibility = 'hidden';
return setAttributes(svg, attrs);
}