Open anvish2 opened 1 year ago
I think you might have a malformed file, since you have a defs
in defs
, don't know if thats allowed.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<defs>
<defs>
<path id="a" d="M423.69 131.81h350.88v413.67H423.69z"/>
</defs>
<clipPath id="b">
<use width="841.89" height="595.28" xlink:href="#a"/>
</clipPath>
</defs>
<path fill="#fd0" stroke="#000" stroke-width=".458" d="M700.52 304.98c13.331-13.353 28.933-28.998 36.853-37.016 2.537-2.568.719 99.61.719 144.98 0 21.273-13.272 96.323-91.104 58.556 0 0-38.89-13.962-50.247-30.79 2.646 0 5.267-.169 7.851-.495 1.183.634 2.446 1.226 3.775 1.775 44.896 30.248 71.666 7.998 71.666 7.998 24.757-15.589 28.807-63.192 28.425-69.688" clip-path="url(#b)" transform="matrix(1.1464 0 0 1.1712 -486.82 -157.86)"/>
</svg>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<defs>
<path id="a" d="M423.69 131.81h350.88v413.67H423.69z"/>
<clipPath id="b">
<use width="841.89" height="595.28" xlink:href="#a"/>
</clipPath>
</defs>
<path fill="#fd0" stroke="#000" stroke-width=".458" d="M700.52 304.98c13.331-13.353 28.933-28.998 36.853-37.016 2.537-2.568.719 99.61.719 144.98 0 21.273-13.272 96.323-91.104 58.556 0 0-38.89-13.962-50.247-30.79 2.646 0 5.267-.169 7.851-.495 1.183.634 2.446 1.226 3.775 1.775 44.896 30.248 71.666 7.998 71.666 7.998 24.757-15.589 28.807-63.192 28.425-69.688" clip-path="url(#b)" transform="matrix(1.1464 0 0 1.1712 -486.82 -157.86)"/>
</svg>
This was excerpt from a real-world example: https://en.wikipedia.org/wiki/Coat_of_arms_of_Ecuador
This was excerpt from a real-world example: https://en.wikipedia.org/wiki/Coat_of_arms_of_Ecuador
FYI: I repaired https://commons.wikimedia.org/wiki/File:Coat_of_arms_of_Ecuador.svg
scour breaks SVG by deleting referenced element.
Original file:
Compressed file:
Note that "defs241" is removed despite "SVGID9" being referenced. This leads to broken image.
Workaround is to set "--keep-unreferenced-defs".