Dashed 'Print' command produce faulty print on PDF printer

Hi there,

In the past, I used to use the ‘PDF Creator’ printer in order to batch output layouts as PDF, through scripting.

It seems that the dashed version of ‘Print’ is not working properly any more: if I print a test layout with ‘Print’, the preview window is displayed and the PDF is correctly generated: PDFCreator_normal.pdf (3.6 KB)
If I run '-Print G <output path> ', the output PDF is corrupted: PDFCreator_dashed.pdf (15.8 KB)

I also tried some other PDF printers:

  • Rhino PDF:
    – normal ‘Print’ works fine
    – dashed ‘Print’ will open a window to choose the pdf output path > I don’t want to work with GUI, but directly specify the output path in the console…

  • Microsoft Print to PDF
    – works fine with both commands, but that printer seems to be really limited in terms of paper formats…

If someone have any clue about this, I’ll be really thankful…

Hello - can you post an example of the entire macro you are using for -Print?

-Pascal

Hi Pascal,

Here’s my usual workflow:

  • I manually define the printer in the ‘Layout Properties’ window:image

  • Then I run the normal ‘Print’ command to manually set all the settings like ‘Line widths’, ‘Print colors’ etc…

  • It outputs one dummy pdf I delete right after

  • Once settings are fine, I run '-Print ', I do a quick check that the settings are as expected (right Destination etc.):

  • Finally, the print command will just be for example: ‘-Print G “C:\OUT\PDF\rhino_pdf_dashed.pdf”’

Hello - I can see something is broken - thanks for the report.

https://mcneel.myjetbrains.com/youtrack/issue/RH-54195

-Pascal

I can work on a fix for this, but a more flexible approach is to use python for automating the process as outlined here

1 Like

Hi Steve,

Thanks! I wasn’t aware of this rhinocommon feature at all…
I’ll definitely have a check :slight_smile:

EDIT:
I tested the method above:

  • it works fine
  • I don’t have to bother with printer paper formats
  • I don’t have to bother with any third-party PDF-printer
  • I don’t have to check that the pdf is created in order to continue the script execution
  • etc…

Conclusion: I wish I knew it before

Thanks Steve!