mathandy / svgpathtools

A collection of tools for manipulating and analyzing SVG Path objects and Bezier curves.
MIT License
557 stars 142 forks source link

Path order not preserved by flattened_paths() in document.py #178

Open stjohn909 opened 2 years ago

stjohn909 commented 2 years ago

Not sure how best to put this, but the list of paths returned by flattened_paths is not in the order it would be drawn by a renderer, because the resulting list is out of order from the sequence in the SVG file.

I'll add a test case when I can get to my workstation, but it looks like a child of one or more transforms appearing in the document before several others at the same level in the hierarchy will be added to the resulting path list after all the others.