[solved] From FreeCad via Inkscape to a plotter (*.plt)

Post questions on how to use or achieve an effect in Inkscape.
chrisond
Posts: 5
Joined: Thu Mar 07, 2019 10:25 pm

[solved] From FreeCad via Inkscape to a plotter (*.plt)

Postby chrisond » Thu Mar 07, 2019 10:45 pm

Hello everybody,

I am stuck in a conversion process:

I export an *.svg from FreeCAD to open it in Inkscape and save it as a *plt.

The bug message is this:

UniConvertor failed:

Traceback (most recent call last):
File "/Applications/Inkscape.app/Contents/Resources/lib/python2.7/site-packages/sk1libs/filters/import/svgloader.py", line 1305, in Load
xml_reader.parse(input_source)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/xml/sax/expatreader.py", line 110, in parse
xmlreader.IncrementalParser.parse(self, source)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/xml/sax/xmlreader.py", line 125, in parse
self.close()
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/xml/sax/expatreader.py", line 226, in close
self._cont_handler.endDocument()
File "/Applications/Inkscape.app/Contents/Resources/lib/python2.7/site-packages/sk1libs/filters/import/svgloader.py", line 559, in endDocument
self.parseElements(element)
File "/Applications/Inkscape.app/Contents/Resources/lib/python2.7/site-packages/sk1libs/filters/import/svgloader.py", line 579, in parseElements
getattr(self, method)(attrs)
File "/Applications/Inkscape.app/Contents/Resources/lib/python2.7/site-packages/sk1libs/filters/import/svgloader.py", line 915, in rect
self.parse_attrs(attrs)
File "/Applications/Inkscape.app/Contents/Resources/lib/python2.7/site-packages/sk1libs/filters/import/svgloader.py", line 654, in parse_attrs
self.parse_style(val)
File "/Applications/Inkscape.app/Contents/Resources/lib/python2.7/site-packages/sk1libs/filters/import/svgloader.py", line 667, in parse_style
self.try_add_style(key, val)
File "/Applications/Inkscape.app/Contents/Resources/lib/python2.7/site-packages/sk1libs/filters/import/svgloader.py", line 750, in try_add_style
self.style.line_cap = cap[val]
KeyError: u'miter'
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/Applications/Inkscape.app/Contents/Resources/lib/python2.7/site-packages/uniconvertor/__init__.py", line 95, in uniconv_run
doc = load.load_drawing(input_file)
File "/Applications/Inkscape.app/Contents/Resources/lib/python2.7/site-packages/uniconvertor/app/io/load.py", line 377, in load_drawing
return load_drawing_from_file(file, filename)
File "/Applications/Inkscape.app/Contents/Resources/lib/python2.7/site-packages/uniconvertor/app/io/load.py", line 354, in load_drawing_from_file
raise SketchLoadError(_("Parsing error: ")+ str(value))
app.events.skexceptions.SketchLoadError: Parsing error: u'miter'


I could solve the problem once with the following procedure in Inkscape:

1 - Select All

2 - Path > Object to path

3 - (with everything still selected) Object > Group

This time this solution doesn t work.
Anybody able to interpret the UniConvertor message?
Thanx in advance!!!

Cheers community!
Last edited by chrisond on Tue Mar 12, 2019 12:15 am, edited 1 time in total.

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

Re: From FreeCad via Inkscape to a plotter (*.plt)

Postby brynn » Fri Mar 08, 2019 3:16 am

What is your Inkscape version and operating system? Also maybe check if your Uniconverter version is current?

Sorry, I can't decipher the error message. But others will be around shortly, who can.

chrisond
Posts: 5
Joined: Thu Mar 07, 2019 10:25 pm

Re: From FreeCad via Inkscape to a plotter (*.plt)

Postby chrisond » Fri Mar 08, 2019 5:26 am

Sure,

I am workin on a (updated) Mac Os High Sierra 10.13.6.
Inkscape 0.92 communicates via
XQuartz 2.7.11 (xorg-server 1.18.4).

With other files coming from FreeCAD Inkscape worked, even if non-geometric data like dimensions were involved...

Moini
Posts: 3381
Joined: Mon Oct 05, 2015 10:44 am

Re: From FreeCad via Inkscape to a plotter (*.plt)

Postby Moini » Fri Mar 08, 2019 10:38 am

Can you share the file? Then we might find the object that causes this.
Something doesn't work? - Keeping an eye on the status bar can save you a lot of time!

Inkscape FAQ - Learning Resources - Website with tutorials (German and English)

chrisond
Posts: 5
Joined: Thu Mar 07, 2019 10:25 pm

Re: From FreeCad via Inkscape to a plotter (*.plt)

Postby chrisond » Sat Mar 09, 2019 7:43 am

Yeah, sure,
there are 2 svg-files with similar error messages. (bauchi1...).
Than I attached an older but "working" svg-file of the same project (bauchi_vorne).

Thanx for your interest by the way

cheers
c/o
Attachments
bauchi_vorne.svg
(15.19 KiB) Downloaded 115 times
bauchi1_vorne_neu.svg
(21.33 KiB) Downloaded 112 times
bauchi1_hinten.svg
(149.49 KiB) Downloaded 113 times

Moini
Posts: 3381
Joined: Mon Oct 05, 2015 10:44 am

Re: From FreeCad via Inkscape to a plotter (*.plt)

Postby Moini » Sun Mar 10, 2019 3:29 am

Hi Chrisond, I was able to convert the files after:

- ungrouping everything completely
- converting everything to a path

(and after fixing uniconvertor, building and then installing it.... lol)
Something doesn't work? - Keeping an eye on the status bar can save you a lot of time!

Inkscape FAQ - Learning Resources - Website with tutorials (German and English)

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

Re: From FreeCad via Inkscape to a plotter (*.plt)

Postby tylerdurden » Sun Mar 10, 2019 11:52 am

Some issues in the svg:
    Pattern fills cause failure (see in browser)
    Title block and border cause failure

Might dig deeper, but that will take time.
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/

chrisond
Posts: 5
Joined: Thu Mar 07, 2019 10:25 pm

Re: From FreeCad via Inkscape to a plotter (*.plt)

Postby chrisond » Sun Mar 10, 2019 10:32 pm

It's easy - I was briefed in the FreeCAD-Forum...svg > hpgl (which is kind of a less sensitive /proprietary version of plt) > plt.
Problem solved. The shortcomings of the files ( no tangential constraints, title blocks) still exist, but...who cares.

Thanx to all of you!!!

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

Re: From FreeCad via Inkscape to a plotter (*.plt)

Postby tylerdurden » Mon Mar 11, 2019 9:21 am

Yeah, not too sure about that workflow... I made a SVG>HPGL>PLT round trip back into Inkscape and there seem to be a lot of extra paths right on top of each other. :-/
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/

chrisond
Posts: 5
Joined: Thu Mar 07, 2019 10:25 pm

Re: From FreeCad via Inkscape to a plotter (*.plt)

Postby chrisond » Tue Mar 12, 2019 12:00 am

true, thanks, for whatever reason the dimensions flipped back to the origin.
Work in progress!!!


Return to “Help with using Inkscape”