[Bug 714731] Re: remove more attributes with default values
jazzynico
714731 at bugs.launchpad.net
Sat Feb 14 15:05:53 UTC 2015
** Changed in: inkscape
Status: Fix Committed => Fix Released
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to scour in Ubuntu.
https://bugs.launchpad.net/bugs/714731
Title:
remove more attributes with default values
Status in Inkscape: A Vector Drawing Tool:
Fix Released
Status in Scour - Cleaning SVG Files:
Fix Released
Status in scour package in Ubuntu:
Fix Released
Bug description:
Within removeDefaultAttributeValues, scour removes some attributes if
they have default values and are therefore unnecessary, but this list
of default values is rather short and conservative. It would be nice
if scour could also get rid of default attribute values like fill-
rule:nonzero and stroke-linecap:butt and a lot of other stuff Inkscape
loves to include.
There is a problem, though: if an element changes such a value, and a
child element sets the value back to the default value, we can’t
delete this attribute in the child element, since the default value is
now meaningful. Therefore, it is necessary to keep track whether some
attribute has been changed somewhere among the ancestors, in which
case an attribute pointing to a default value should be left
untouched.
I appended a code fragment where I made the necessary changes to the
removeDefaultAttributeValues function. The rest of the code is
unaffected, although my changes could be used to make repairStyle
shorter (and remove a known problem of the way repairStyle deals with
cases of opacity=1 attributes and their relatives).
To manage notifications about this bug go to:
https://bugs.launchpad.net/inkscape/+bug/714731/+subscriptions
More information about the foundations-bugs
mailing list