2D dxf export, hidden lines not dashed

Discussions about the development of the TechDraw workbench
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
thschrader
Veteran
Posts: 3156
Joined: Sat May 20, 2017 12:06 pm
Location: Germany

2D dxf export, hidden lines not dashed

Post by thschrader »

Hello,
I want to export this part as pdf/dxf. dxf is needed for import into AutoCAD.
When exporting the pdf (right click on page), the hidden lines remain dashed (zoom in pdf),
but for dxf-export the lines are not dashed. I tried shape2Dview from arch-wb too.
Do I miss something?
Thanks Thomas

Discussion started in german forum:
https://forum.freecadweb.org/viewtopic.php?f=13&t=69494

File:
Rahmenknoten_Mast.FCStd
(129.69 KiB) Downloaded 13 times
OS: Windows 10 Version 2009
Word size of FreeCAD: 64-bit
Version: 0.20.27428 (Git)
Build type: Release
Branch: master
Hash: 27460358508a2057e0ec57a418641435f12628dd
Python version: 3.8.6+
Qt version: 5.15.2
Coin version: 4.0.1
OCC version: 7.5.3
Locale: German/Germany (de_DE)
techdrawDXF.JPG
techdrawDXF.JPG (57.5 KiB) Viewed 537 times
User avatar
Roy_043
Veteran
Posts: 8550
Joined: Thu Dec 27, 2018 12:28 pm

Re: 2D dxf export, hidden lines not dashed

Post by Roy_043 »

Confirmed.

There is a potential workaround, but it is a bit involved:
  1. Export the current page to DXF.
  2. Change all hidden HLR parameters to false.
  3. Create a separate DXF.
  4. Move to AutoCAD.
  5. Open the first DXF and change the linetype of all lines to hidden.
  6. Insert the 2nd DXF and explode the block.
  7. Optionally use the OverKill command to get rid of duplicate lines (adjust its settings to ignore linetypes). Depending on the result you may have to change the order of the previous steps: Open the 2nd DXF and insert the 1st DXF.
Attachments
td-hidden-lines-dxf.png
td-hidden-lines-dxf.png (6.95 KiB) Viewed 500 times
User avatar
wandererfan
Veteran
Posts: 6315
Joined: Tue Nov 06, 2012 5:42 pm
Contact:

Re: 2D dxf export, hidden lines not dashed

Post by wandererfan »

thschrader wrote: Sat Jun 18, 2022 7:48 am When exporting the pdf (right click on page), the hidden lines remain dashed (zoom in pdf),
but for dxf-export the lines are not dashed. I tried shape2Dview from arch-wb too.
The dxf export function lives in the App part of TechDraw, This allows dxf exporting in "headless" mode. The downside is that the App part doesn't know about line attributes. Also, I'm not sure if the actual dxf exporter in the Import module supports line attributes. I will have a look.

The pdf export function lives in the Gui part of TechDraw, which does know about line attributes.

The dxf export could probably be enhanced for this, but it would not be a trivial task.
Post Reply