Different lineweights PDF Export vs dwg2pdf

If you are having problems with QCAD, post here. Please report bugs through our Bug Tracker instead.

Always attach your original DXF or DWG file and mentions your QCAD version and the platform you are on.

Moderator: andrew

Forum rules

Always indicate your operating system and QCAD version.

Attach drawing files and screenshots.

Post one question per topic.

Post Reply
BrianLogan
Newbie Member
Posts: 7
Joined: Thu Oct 22, 2020 9:49 am

Different lineweights PDF Export vs dwg2pdf

Post by BrianLogan » Mon Mar 04, 2024 8:53 pm

Hi,

OS: Windows 11
QCAD Version: 3.29.4.0 (3.29.4)

When using PDF Export I see different lineweight to using dwg2pdf.

Code: Select all

"C:\Program Files\QCAD\dwg2pdf.bat" -auto-fit -force -landscape -margin=5 -monochrome -paper=A4 test.dxf
If I use -max-lineweight=0.35, it adjusts the lineweight to that expected, but this would mean I couldn't use any bigger lineweights. Any ideas?

Code: Select all

"C:\Program Files\QCAD\dwg2pdf.bat" -auto-fit -force -landscape -margin=5 -monochrome -paper=A4 -max-lineweight=0.35 test.dxf
With PDF Export:
Image

With dwg2pdf:
Image
Attachments
test.dxf
(94.89 KiB) Downloaded 31 times
dwg2pdf.png
dwg2pdf.png (1.22 KiB) Viewed 698 times
PDF Export.png
PDF Export.png (1.03 KiB) Viewed 698 times

CVH
Premier Member
Posts: 3480
Joined: Wed Sep 27, 2017 4:17 pm

Re: Different lineweights PDF Export vs dwg2pdf

Post by CVH » Tue Mar 05, 2024 6:26 am

Hi, and welcome to the QCAD forum.

PDF export uses the print settings stored in the drawing.
See: Drawing Preferences .. Printing .. Page

Scale = 9.23 ; Offset (38.9112, 38.6241) ; A4
Your 30mm long line is printed as 276.9mm long on a A4 in portrait what is 297mm long.
Probably the drawing was already fitted to paper and centered before.

If we zoom in closely in print preview mode the line width is from 49.981 to 50.019 what is about 0.038 wide.
Multiplied by the paper scale that is 0.35074 what is a match with 0.35mm (ISO) give or take some measurements errors.
In that scale the page is just over 22.6 by 32 units what is again a reasonable match with A4.

So, no surprises there. :wink:

Using QCAD Command Line Tools is practically out of the question on my Win7.
Or qcadcmd.com is not recognized or I get 'Access denied' and when I tweak all that then QCAD reports 'Cannot import file' .... :oops:

Please include example files as per forum rules, and in this case the PDF exported by dwg2pdf :wink:

Regards,
CVH

BrianLogan
Newbie Member
Posts: 7
Joined: Thu Oct 22, 2020 9:49 am

Re: Different lineweights PDF Export vs dwg2pdf

Post by BrianLogan » Tue Mar 05, 2024 9:35 am

Hi,

I included the dxf, but never thought to include the PDFs. Now attached.

Both methods are set to fit drawing to page, but it's the line thickness that's different.

The PDF Export looks as I would expect. It's dwg2pdf output that is a much thicker line.
Attachments
test (PDF Export).pdf
(1.22 KiB) Downloaded 26 times
test (dwg2pdf).pdf
(1.22 KiB) Downloaded 25 times

CVH
Premier Member
Posts: 3480
Joined: Wed Sep 27, 2017 4:17 pm

Re: Different lineweights PDF Export vs dwg2pdf

Post by CVH » Tue Mar 05, 2024 12:42 pm

What happens if you use the named paper size as per example: -paper="A4" ?

For the rest I need to agree that both pdf files are A4 (some App report that as 11.69 × 8.26 in)
And that the file test (dwg2pdf).pdf shows a much thicker line.

Let's see if someone else can verify that. :wink:

Regards,
CVH

BrianLogan
Newbie Member
Posts: 7
Joined: Thu Oct 22, 2020 9:49 am

Re: Different lineweights PDF Export vs dwg2pdf

Post by BrianLogan » Tue Mar 05, 2024 1:32 pm

I already had -paper=A4 in the dwg2pdf command. I tried it again with -paper="A4" and it makes no difference.

CVH
Premier Member
Posts: 3480
Joined: Wed Sep 27, 2017 4:17 pm

Re: Different lineweights PDF Export vs dwg2pdf

Post by CVH » Tue Mar 05, 2024 1:50 pm

OK, finally got it working ... :roll:
Only functional with the file under the QCAD folder, Started OS Command Line as admin, already with the current directory pointing to QCAD, ...
... Renewed exclusions for the Antivirus and Defender, this time for the complete QCAD folder and below ... And so on.

Got two remarkable returns: :shock:
  • 13:15:24: Debug: dropped global XDATA (no res buf): "ViewportCenter"
  • Warning: old and new property values for property "Arrow block" have different types: QString vs. int
"Arrow" only occurs twice textual in the DXF file in relation with a Linetype ... RIGHT_ARROW

The pdf file created with dwg2pdf under QCAD version 3.27.6 looks fine to me.
test2pdf.pdf
(1.22 KiB) Downloaded 25 times

I might give that a go with version 3.29.4.0 after updating ...
... If I really want that (Unanswered: https://www.qcad.org/rsforum/viewtopic.php?f=8&t=9601).
But a trial version should work just the same ...

Regards,
CVH

CVH
Premier Member
Posts: 3480
Joined: Wed Sep 27, 2017 4:17 pm

Re: Different lineweights PDF Export vs dwg2pdf

Post by CVH » Tue Mar 05, 2024 2:30 pm

I can confirm that dwg2pdf version 3.29.4.0 exports a thick line.

Probably something for QCAD bugtracker:
https://qcad.org/bugtracker/

Removing trial version 3.29.4.0 ... :roll:

Regards,
CVH

BrianLogan
Newbie Member
Posts: 7
Joined: Thu Oct 22, 2020 9:49 am

Re: Different lineweights PDF Export vs dwg2pdf

Post by BrianLogan » Tue Mar 05, 2024 3:43 pm

Thanks for confirming it's OK on an earlier version. Yes, it looks as expected on your attached PDF. I've reported it as a bug.

Post Reply

Return to “QCAD Troubleshooting and Problems”