Today I was exporting a fritzing file which contains wires with bendpoints, aka segments, both curved and straight in the same wire, when I realized two things:
- The straight wire segments are exported as “line” SVG elements, while the curved segments are exported as “path” elements
- Every segment is separated, which gives a non-continuous wire (see image).
My goal is to create a Python tool (script) to “fix” that export so I can get continous wires combined in uniques paths. As far as I can tell now, that would involve two steps:
- locate all (SVG) line elements that form a wire
- join them in an unique path element (both internal color and external color).
Has anyone done/tried that before? I have searched the forum without success, but want to ask before reinventing the wheel…