[SOLVED] File size question

General discussions about Inkscape.
User avatar
Ponny
Posts: 101
Joined: Wed Oct 10, 2007 3:02 am
Location: Mystic kingdom of Krakovo

[SOLVED] File size question

Postby Ponny » Sun Aug 02, 2015 10:43 pm

Meow

I have a little bit strange problem. Nothing very important, but is interesting.

There are two inkscape files. Very similar. The same group of object in both.

Only difference is this:
objects in first file "vaja 1a1.svg" has more nodes, than in second file "vaja 1b1.svg".

But the second file has bigger file size, than first.
Is this normal, or maybe is there some error in file(s)?


Thankyou in advance and sorry for stupid question.
Attachments
vaja 1b1.svg
Second file
(6.22 KiB) Downloaded 160 times
vaja 1a1.svg
First file
(5.13 KiB) Downloaded 212 times
Last edited by Ponny on Wed Aug 17, 2016 6:53 pm, edited 1 time in total.
Did you see the indigo Pony, when he came from other side wall of the night?

User avatar
brynn
Posts: 10309
Joined: Wed Sep 26, 2007 4:34 pm
Location: western USA
Contact:

Re: File size question

Postby brynn » Sun Aug 02, 2015 11:41 pm

I say, we can't learn if we don't ask questions! And that's why we're here, to help each other :D

Are you familiar with File menu > Clean Up Document? It used to be called "Vacuum Defs" before 0.91. Do you understand what it does?

In case you aren't, it removes data that was placed in the file, but by the time you finish with the drawing, some data ended up not being used. Like maybe you tried a few different gradients. Or practiced with some filters. And there are all kinds of things that add data to the file, but when you delete them, it only deletes them from the canvas. But the data is still in the file (where you can't see it, without knowing where to look)(I don't know where that is).

So maybe in the 2nd file you had somehow added extra data to the file, which in the end, you decided not to use. Try using File menu > Clean Up Doc on both of those file. I would expect they will be closer to the same size.

I haven't looked at your files yet, or tried that myself. Maybe other people will have some other ideas about this?

tylerdurden
Posts: 2344
Joined: Sun Apr 14, 2013 12:04 pm
Location: Michigan, USA

Re: File size question

Postby tylerdurden » Mon Aug 03, 2015 7:52 am

We can see differences by simply looking at the files in a text editor.

I have deleted all the paths in both files except for the first "branch". In Inkscape you can see b1 has smooth nodes, this is reflected in the file data:

Code: Select all

Compare: (<)C:\Documents and Settings\TD\My Documents\Inkscape\misc\ponny\vaja 1b1.svg (2097 bytes)
   with: (>)C:\Documents and Settings\TD\My Documents\Inkscape\misc\ponny\vaja 1a1.svg (1916 bytes)

15c15
<    sodipodi:docname="vaja 1b1.svg">
---
>    sodipodi:docname="vaja 1a1.svg">
<snip>
<      sodipodi:nodetypes="cc"
<      inkscape:connector-curvature="0"
<      id="path4914"
<      d="M 594.70312,328.92329 C 584.9109,323.32072 574.273,323.13046 564.81905,322.77106"
<      style="color:#000000;display:inline;overflow:visible;visibility:visible;fill:none;stroke:#c00000;stroke-width:1.25;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker:none;enable-background:accumulate" />
---
>      inkscape:connector-curvature="0"
>      id="path452"
>      d="M 499.0371,264.0823 485.8536,260.5668 472.6702,259.6878"
>      style="fill:none;stroke:#c00000;stroke-width:1.25;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" />


You can see there is a declaration: "sodipodi:nodetypes="cc" for each path, plus curvature data and a bit more style info.

This can also be seen in the xml editor inside Inkscape, but sometimes a text editor is easier.
Have a nice day.

I'm using Inkscape 0.92.2 (5c3e80d, 2017-08-06), 64 bit win8.1

The Inkscape manual has lots of helpful info! http://tavmjong.free.fr/INKSCAPE/MANUAL/html/


Return to “General Discussions”