View Issue Details

IDProjectCategoryView StatusLast Update
0004454FreeCADFeaturepublic2021-09-07 21:40
Reporterefa Assigned To 
Status confirmedResolutionopen 
Target Version0.20 
Summary0004454: DXF files open with wrong line thickness. Resaving lost thickness information
the line thickness when importing DXF is wrong.
The exported files become corrupt lost thickness information
Steps To ReproduceOpen a DXF file with line thinckness set, use the attached as test.
The line property "polyline width" is not rendered
Export as DXF
Open the exported DXF with QCAD pro, the line thinkness is wrong
Additional Informationthe problem is present in LibreCAD and QCAD Community edition too, see:

QCAD Pro and Autodesk TrueView open DXF correctly
FreeCAD InformationOS: Windows 10 (10.0)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.22665 (Git)
Build type: Release
Branch: master
Hash: b0d7850406e046f3b7a8cd5da261e7d54df6bd99
Python version: 3.8.6
Qt version: 5.12.9
Coin version: 4.0.0
OCC version: 7.4.0
Locale: Italian/Italy (it_IT)



2020-10-09 13:20


PCBtracks_demo.7z (14,832 bytes)
PCBtracks_demo.png (119,668 bytes)   
PCBtracks_demo.png (119,668 bytes)   


2020-10-09 21:09

developer   ~0014805

@efa : please address your issue according our reporting guidelines by opening a new topic on our forum. Thx


2020-10-10 19:59

reporter   ~0014827


2020-10-10 20:15

reporter   ~0014828

Last edited: 2020-10-10 20:18

PCBtracks_demo_FreeCAD.png (154,729 bytes)   
PCBtracks_demo_FreeCAD.png (154,729 bytes)   


2020-10-10 20:18

reporter   ~0014829

see how is rendered by FreeCAD last stable on Linux:

OS: LMDE 4 (debbie)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.18.
Build type: Release
Python version: 2.7.16rc1
Qt version: 5.11.3
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: Italian/Italy (it_IT)

same as 0.19 on Windows


2021-02-07 06:02

administrator   ~0015285

I can confirm this in:
OS: Windows 10 Version 2004
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.23935 (Git)
Build type: Debug
Branch: master
Hash: d5b68febbb4989b290b9af36bb2cb21d61a87a2e
Python version: 3.8.6+
Qt version: 5.15.1
Coin version: 4.0.1
OCC version: 7.5.0
Locale: English/United States (en_US)

The width is simply being exported as the scale, rather than whatever the value of the width was supposed to be. If you use the FreeCAD option renderPolylineWidth in the DXF import preferences settings you can get FC to try to render the line with width, but this does not fix the export issue.


2021-02-07 15:34

reporter   ~0015297

on Linux, 0.19dev also with renderPolylineWidth in the DXF import active, I can't see right tickness:

OS: LMDE 4 (debbie) (MATE/mate)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.23756 (Git) AppImage
Build type: Release
Branch: master
Hash: 9c6e9184930a52b165a0b7274e3a45d1006bfe67
Python version: 3.8.6
Qt version: 5.12.5
Coin version: 4.0.0
OCC version: 7.4.0
Locale: Italian/Italy (it_IT)


2021-08-26 15:10

administrator   ~0015869

FreeCAD's lines don't have the concept of individual width -- using the user preference option "Render Polylines with Width" will allow the conversion of the lines into rectangles internally so that this file displays more correctly. But note that this will change their representation in any DXF file that is then exported from FreeCAD. I've marked this as a "feature request" as in the long term, improved import and export of DXF files might be desirable.


2021-08-27 14:08

reporter   ~0015878

Last edited: 2021-08-28 14:10

just upgraded from
I keep the Preference, Import/Export, DXF: Draw polyline width set
but I still get all lines at minimum width as in the PCBtracks_demo_FreeCAD.png
I cannot get rectangles


2021-09-06 20:11

administrator   ~0015906

Are you using the legacy Python importer? I don't think the newer C++ importer supports the width parameter at all yet.


2021-09-06 20:28

reporter   ~0015907

I think it is the default one.
How can I check which importer is used?


2021-09-07 14:02

administrator   ~0015908

Preferences->Import/Export->DXF->Use Python Legacy Importer (which is not the default, I don't think).


2021-09-07 17:35

reporter   ~0015910

it was selected "Usa il vecchio importatore python" that should be the Python Legacy Importer, I de-selected it, but the results is the same.
Attached the dialog box, is there something I had to set different?
FreeCAD_DXFinport.png (291,515 bytes)   
FreeCAD_DXFinport.png (291,515 bytes)   


2021-09-07 21:15

administrator   ~0015911

You should have "Usa il vecchio importatore python" checked, but that's otherwise correct I think. When I select those options this is what I get:
PCB_Test.png (77,483 bytes)   
PCB_Test.png (77,483 bytes)   


2021-09-07 21:38

reporter   ~0015912

Last edited: 2021-09-07 21:40

OK, using the old python importer I get your output, and its lot better.
Probably in the past I had selected only old python exporter


2022-03-03 13:55

administrator   ~0016945

This ticket has been migrated to GitHub as issue 6112.

Issue History

Date Modified Username Field Change
2020-10-09 13:20 efa New Issue
2020-10-09 13:20 efa File Added: PCBtracks_demo.7z
2020-10-09 13:20 efa File Added: PCBtracks_demo.png
2020-10-09 21:09 openBrain Status new => feedback
2020-10-09 21:09 openBrain Note Added: 0014805
2020-10-10 19:59 efa Note Added: 0014827
2020-10-10 19:59 efa Status feedback => new
2020-10-10 20:15 efa Note Added: 0014828
2020-10-10 20:15 efa File Added: PCBtracks_demo_FreeCAD.png
2020-10-10 20:17 efa Note Edited: 0014828
2020-10-10 20:18 efa Note Edited: 0014828
2020-10-10 20:18 efa Note Added: 0014829
2020-10-11 01:10 Kunda1 Tag Attached: #pending-forum
2020-10-11 01:11 Kunda1 Tag Attached: DXF
2020-10-11 01:11 Kunda1 Target Version => 0.19
2021-02-06 06:49 abdullah Target Version => 0.20
2021-02-07 06:02 chennes Note Added: 0015285
2021-02-07 15:34 efa Note Added: 0015297
2021-08-25 23:45 chennes Tag Detached: #pending-forum
2021-08-26 15:05 chennes Severity major => feature
2021-08-26 15:05 chennes Status new => confirmed
2021-08-26 15:05 chennes Category Bug => Feature
2021-08-26 15:10 chennes Note Added: 0015869
2021-08-27 14:08 efa Note Added: 0015878
2021-08-28 14:10 efa Note Edited: 0015878
2021-09-06 20:11 chennes Note Added: 0015906
2021-09-06 20:28 efa Note Added: 0015907
2021-09-07 14:02 chennes Note Added: 0015908
2021-09-07 17:35 efa Note Added: 0015910
2021-09-07 17:35 efa File Added: FreeCAD_DXFinport.png
2021-09-07 21:15 chennes Note Added: 0015911
2021-09-07 21:15 chennes File Added: PCB_Test.png
2021-09-07 21:38 efa Note Added: 0015912
2021-09-07 21:39 efa Note Edited: 0015912
2021-09-07 21:40 efa Note Edited: 0015912