Python API issue - sketch.importSVG( filename, 0, 0, 0)

balunist
Advocate
Advocate

Python API issue - sketch.importSVG( filename, 0, 0, 0)

balunist
Advocate
Advocate

This method has some strange defaults.   When I insert my SVG file with the user interface using the defaults it works as expect.   The size is correct, orientation is correct, and it is placed in the lower right quadrant.   When I execute the sketch.importSVG( filename, 0, 0, 0) method

the size is roughly 38 time the expected size, flipped vertically (text is still forward facing), and it is placed in the upper right quadrant.  

 

Attached is a png of the user interface defaults for insert->insert SVG that worked.  The Post would not allow me to attached the actual SVG file I'm inserting.   I can email on request.

 

Thanks in advance for your help!

Bill Vanca

 

0 Likes
Reply
430 Views
1 Reply
Reply (1)

ekinsb
Alumni
Alumni

Thanks for reporting this.  I'm able to reproduce the problem and have logged a bug.  The "SVG Import" command has had some changes since the API was initially implemented and the API needs to be updated to provide the latest capabilities.


Brian Ekins
Inventor and Fusion 360 API Expert
Mod the Machine blog
0 Likes