Inkscape.org
Beyond the Basics Getting statiscs from an SVG file
  1. #1
    Freezr Freezr @freezr

    Hi Inkscapers,

    is there a way to get statics from Inkscape about your opened document like, for instance: nodes. paths, groups, colors, layers etc?

    Or do you know any CLI utility that is useful for?

    Thanks,

    F.

  2. #2
    Freezr Freezr @freezr
    *

    I found this project:

    https://angelmmiguel.github.io/svgi/

    I am trying the binary version I do not want dirt my system with NPM and other javascript garbage...

    It worked even though the binary version was unable to measure the weight of the file...

  3. #3
    Paddy_CAD Paddy_CAD @Paddy_CAD

    Are your files very heavy? What have you been feeding them?

  4. #4
    inklinea inklinea @inklinea⛰️

    It's possible there is an extension out there somewhere.

    The question is where ? :)

    A very basic count would be

    1. make a copy of the svg 

    2. remove any <def> sections so for example marker paths are not counted in error.

    3. Run an .xpath search for the svg ( or selected element if you like ) 

    As with most things 80% of the work is in polishing the final details.

    Peek 2022 09 03 00 13
Inkscape Inkscape.org Inkscape Forum Beyond the Basics Getting statiscs from an SVG file