Invalid import from dxf

Bug #1700582 reported by Roman
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Inkscape
Fix Released
Undecided
Alvin Penner

Bug Description

Hi,

I added support DXF in my app and checked result in Inkscape. And think that i have found a bug. Where AutoCAD shows expected result Inkscape makes a path closed.

My version is 0.92.1 on Ubuntu.

I attached two files that show the problem.

valid.dxf - this file is not imported correctly in Inkscape.
invalid.dxf - imported incorrectly, but looks exactly how i need.

I guess the problem in this case is LWPOLYLINE option with code 70.

From documentation:
LWPOLYLINE
70 - Polyline flag (bit-coded); default is 0: 1 = Closed; 128 = Plinegen

Looks like Inkscape recognize only closed state, but when i set also plinegen it closes a path. Value 128 is also treats as closed, but it should not.

Revision history for this message
Roman (dismine) wrote :
Revision history for this message
Alvin Penner (apenner) wrote :

attached is a modified version of the file dxf_input.py, which fixes the bug.
in order to apply this fix you will need to copy this file into the location Inkscape\share\extensions\. You may wish to make a backup copy of your current file first, just in case.

Changed in inkscape:
status: New → Confirmed
status: Confirmed → In Progress
assignee: nobody → Alvin Penner (apenner)
Revision history for this message
Roman (dismine) wrote :

Just tested and for me works. Thanks.

Revision history for this message
Alvin Penner (apenner) wrote :

good to hear. merged with trunk in rev:

https://gitlab.com/inkscape/inkscape/commit/9787f22c

Changed in inkscape:
status: In Progress → Fix Committed
Max Gaukler (mgmax)
Changed in inkscape:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.