@andrea.settimi wrote:
Hello there!
I am trying to batch print quite a few .3dm files. Each one has a different background color for the layout, and what I would like to achieve is simply to print the layout integrating the appropiate background-color.
Now, I have a small script (provided by @lando.schumpich) which is able to print layouts without passing through the pop-up printing settings.
I have tried to use "Rhino.Display.ViewCaptureSettings.DrawBackground " but I do not really know how to integrate it into the settings of pdf.AddPage.
Could anyone give me a hint? Thank you in advance!Here’s the code:
def createSinglePDF(view):
pdf = Rhino.FileIO.FilePdf.Create()
dpi = 300
settings = Rhino.Display.ViewCaptureSettings(view, dpi)
pdf.AddPage(settings)
filename = ‘{0}{1}.pdf’.format(sPath, nameProject)
pdf.Write(filename)EDIT: just to be clear about the problem. Here’s my workspace:
And here’s the “wrong” output not considering the background color:
Posts: 3
Participants: 2