Customizing PDF output properties when printing via PDFNet Virtual Print Driver

54 views
Skip to first unread message

Support

unread,
Aug 26, 2013, 3:03:03 PM8/26/13
to pdfne...@googlegroups.com
Q:
 
I’m wondering what PDF output properties (line weight, etc..) can be controlled when printing to PDF using the built in PDFNet Virtual Print Driver (https://groups.google.com/d/msg/pdfnet-sdk/WhKFea4SD4s/E57kh8lMCu8J, https://groups.google.com/d/msg/pdfnet-sdk/z98FsCqshqk/sbjSipdInwQJ)?
 

Line weights

Multi-page capabilities

Unattended batch processing

Quality settings (screen, photo, e-book, prepress)

Supports Citrix

Supports Terminal Server

Watermarks

Large paper sizes

Linearization

Font embedding

Encryption

Compression

Protection

 

 

-----------

 

A:

The built-in the printer driver doesn't have any output options. It simply captures the spool file (i.e. the XPS) and converts it to PDF. The only way to control/affect spool file generation is via standard Windows print API or by modifying the information that the source application is sending to the printer device context. Once the file is normalized to PDF you can easily add all the required options in a post-processing step.

 

For example, you can encrypt PDF by setting the security handler (as shown in EncTest sample) and save the file with linearization using doc.Save("out.pdf", SDFDoc.SaveOptions.e_linearized) 

 

...  or you can apply watermarks (as shown in Stamper sample, http://www.pdftron.com/pdfnet/samplecode.html#Stamper),

… or down-sample images (as shown in Optimizer sample, http://www.pdftron.com/pdfnet/samplecode.html#Optimizer) etc.

 

To adjust colors & path line weight you would use the approach shown in ElementEdit sample (http://www.pdftron.com/pdfnet/samplecode.html#ElementEdit, you would be modifying SetLineWeight() in element.GetGState()) and so forth.

 
If you are implementing your own driver using PDFTron Virtual Driver SDK you can perform all of the above operations (including others such as emailing PDF) within the driver itself.
 
 
Reply all
Reply to author
Forward
0 new messages