Why are svg files not made smaller using scour?

Hitesh Shah chimak111 at gmail.com
Wed Nov 7 01:03:40 UTC 2012

On Wed, Nov 7, 2012 at 2:50 AM, 神癒礁湖 (Rafael Laguna) <rafaellaguna at gmail.com
> wrote:

> Sorry, missunderstood you.  To reduce file sizes on all icons I use to run
> a script of my own that Inkscape itself healthy to clean them. I use that
> script when updating a whole icon folder.
> But I must warn you that reducing "too much" the svg files may damage some
> xml attributes and become ugly or totally useless. There are some svg
> attributes that I intentionally put in an icon that "shrinkers" ignore.
> --
> 紳癒礁湖 (Rafael Laguna)
> Lubuntu Artwork Team

@Julien, I have no experience in packaging and I've never used the dh

@Julien and @Rafael,

Yes, aggressive use of scour could possibly damage things but I'm not sure
that just the default settings could be harmful. I'll give an example of
the screen output below for scouring
As a precaution I copied the file to my desktop and ran the following
python /usr/share/pyshared/scour.py -i phone.svg -o out.svg

The output on the screen shows what scour did:
[06:17 AM] ~/Desktop $ python /usr/share/pyshared/scour.py -i phone.svg -o
scour 0.26
Copyright Jeff Schiller, Louis Simard, 2010
 File: phone.svg
 Time taken: 0.49s
 Number of elements removed: 53
 Number of attributes removed: 273
 Number of unreferenced id attributes removed: 0
 Number of style properties fixed: 36
 Number of raster images embedded inline: 0
 Number of path segments reduced/removed: 144
 Number of bytes saved in path data: 1728
 Number of bytes saved in colors: 234
 Number of points removed from polygons: 0
 Number of bytes saved in comments: 0
 Number of bytes saved in id attributes: 0
 Number of bytes saved in lengths: 70
 Number of bytes saved in transformations: 403
 Original file size: 56781 bytes; new file size: 24244 bytes (42.69%)
[06:26 AM] ~/Desktop $

I agree that there is a possibility that some files could be damaged, but
in the few days I been playing around, I haven't seen any damage caused by
using scour.
(There are settings that could be make scour more aggressive but I'm only
using the defaults.)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/lubuntu-users/attachments/20121107/8a3ea8ae/attachment.html>

More information about the Lubuntu-users mailing list