Some test text!

Frequently Asked Questions

In this document
chevron_rightIs DocPub available as a toolkit for integration with third party applications?
chevron_rightWhat is XPS?
chevron_rightWhat is XOD?
chevron_rightDoes DocPub have any dependencies on third party components/software?
chevron_rightHow do I convert Microsoft Office formats on Windows?
chevron_rightHow do I convert other file formats not listed on Windows?
chevron_rightHow do I save converted files in a given folder?
chevron_rightHow can I control the output name for the converted files?
chevron_rightHow do I specify which files to convert?
chevron_rightHow do I batch convert files?
chevron_rightHow do I convert a password protected PDF?
chevron_rightHow do I create an encrypted XOD file?
chevron_rightWhat quality can I expect from the output XOD document?

linkIs DocPub available as a toolkit (SDK) for integration with third party applications?

For developers who are looking for more control over the conversion process than a command-line utility can provide, developers can also license DocPub functionality as part of PDFNet SDK and the applicable add-ons for the required conversions (such as WebViewer Add-on for conversion to XOD, or the PDF to HMTL Add-on, etc.). PDFNet SDK is an industry-leading, high-quality document core technology platform powering mobile, server, desktop, web, and cloud-based apps. Using the PDFNet library, developers can create powerful PDF document solutions and applications that can convert, generate, manipulate, optimize, print, view, and markup PDF documents without any third-party software dependencies.

PDFNet SDK is available as a .NET component, and as a cross-platform C/C++, Java, Ruby, Python, PHP and Objective-C, PDF library, that is available on a wide range of platforms (i.e. Windows, Linux, Mac OS X, Android, iOS, Windows 8/RT, etc).

Alternatively, developers can also subscribe to PDFTron Web Services (PWS), a pay-as-you-go platform for licensing the DocPub, WebViewer or PDFNet conversion capabilities. PWS enables developers to sign up to a Cloud account, with the document conversion hosted by PDFTron, or to an On-Premise account with the conversion processing performed on their own servers.

For more details, please contact a PDFTron representative via info@pdftron.com or sales@pdftron.com.

linkWhat is XPS?

"XPS" stands for "XML Paper Specification" and is a new document format as well as the native print spooler format in Microsoft® Windows. The XPS document format consists of XML markup that defines the layout of a document and the visual appearance of each page along with rendering rules for distributing, archiving, rendering, processing and printing the documents. Just like PDF, the XPS document format enables users to view, print, and archive any type of documents without the original program that created them and without loss of fidelity.

To find out more about XPS, please visit Microsoft®'s website

linkWhat is XOD?

XOD is a web optimized Open XPS format developed for hosting documents online. It facilitates fast viewing of large size files while ensuring high quality display.

XOD documents can be stored locally as well, and can also be viewed by any XPS viewer. Any PDF, XPS, or any printable document, can be converted to XOD format with PDFTron's command-line DocPub utility.

linkDoes DocPub have any dependencies on third party components/software?

For most conversions, including PDF, SVG, XPS, XOD, PNG, JPG, etc, DocPub is a completely stand-alone application and does not include any dependencies on third-party components or software. For some other types of conversion, external programs are required, see below.

linkHow do I convert Microsoft Office formats on Windows?

To convert Word, Excel, PowerPoint, Publisher and Visio files, you need either the respective Microsoft application (which we will call Office for short), or another program that can print them, installed on the computer doing the conversion. For best performance, and results, install Microsoft Office. Otherwise, see below.

linkHow do I convert other file formats not listed on Windows?

Finally, to convert any (proprietary or non-standard) document on Windows, you need to have an application that can print the file type.

See the here for more information regarding custom conversions:

linkHow do I save converted files in a given folder?

By default, DocPub saves converted files in the current working folder. To specify another output location, use the '-o' (or --output) parameter. For example:

DocPub --o "c:\My Output" 1.xps 2.jpg 3.doc

Note: If the specified path does not exist, DocPub will attempt to create the necessary folders.

linkHow can I control the output name for the converted files?

DocPub will, by default, create a single file with the name of the input file. The output filename can be changed using the '--suffix' option. For example, the following command-line generates an output document named mydoc_mysuffix.xps:

DocPub --f xod ---suffix _mysuffix mydoc.pdf

linkHow do I specify which files to convert?

DocPub provides the "---extension" option to filter out the specific file types. For example, the following command-line will process only PDF files and will convert them to XOD format.

DocPub --f xod "c:\My Input" ---extension pdf --o "c:\My Output"

linkHow do I batch convert files?

DocPub supports batch conversion of many files in a single pass. To convert all files in a given folder(s) you can use the following syntax:

DocPub --f pdf "c:\My Input" -- o "c:\My Output"

The '--subfolders' option can be used to recursively process all subfolders. For example, the following line will convert all documents in 'myfolder1' and 'myfolder2' as well as all subfolders:

DocPub --subfolders myfolder1 myfolder2

The use of wild characters is also allowed. For example, to convert all PDF files starting with 'x' in the current folder to XOD format use:

DocPub --f xod x*.pdf

linkHow do I convert a password protected PDF?

DocPub will, without user intervention, convert PDF documents secured with a master/owner password. If the document is secured using a user (or 'file open') password, DocPub will prompt you to enter the password.

For unattended conversion, the password can also be specified directly on the command-line using the '-p' (or --pass) option. For example:

DocPub --f xod -p secret secured.pdf

The above command line will convert PDF to XOD and will use the provided password ('secret') to open the secured document (i.e. 'secured.pdf').

Note: DocPub supports all standard security options available in PDF, including 40 and 128 bit RC4 encryption, Crypt filters, and AES (Advanced Encryption Standard) encryption.

linkHow do I create an encrypted XOD file?

To create a XOD file where the individual parts are encrypted with AES 128.

DocPub --f xod -xod_encrypt secret license.pdf

The generated XOD file can be used with one of the PDFTron WebViewer's to decrypt using the password 'secret'.

linkWhat quality can I expect from the output XOD document?

Since DocPub always attempts to maintain the original document appearance, the vast majority of output files will successfully preserve the appearance and quality of the original documents. Occasionally, there will be elements that can't be accurately converted. In these cases DocPub will by default render the necessary elements at 150 dpi or at the resolution given by the --dpi parameter. Note though that there is a cap on how large an image can be, controlled by --max_image_pixels parameter, which by default is 2 megapixels. For this example we will set the cap at 5 megapixels:

DocPub --f xod --dpi 200 --max_image_pixels 5000000 doc.pdf

would render those elements at 200 dots per inch.

In other select cases, to generate the exact appearance of the original PDF document, an entire page may need to be rendered. In these cases rendering can be disabled using the '--norender' option as in the following example:

DocPub --f xod --norender doc.pdf

This option will preserve resolution independent properties of input documents (including fonts, paths, and shadings) as well as text selection and extraction capability in the processing software.

Finally**, there is the option to 'flatten' content. The default when converting to XOD is 'fast' flatten mode, which try to generate a PDF that renders faster on limited speed/memory devices. This can include changing color spaces, to converting complex paths to an image. You can also turn this off to help ensure that as much content is preserved as is.**

DocPub --f xod --flatten off doc.pdf

If you want to flatten, there is a way to control how much is flattened, or not, by adjusting the flatten threshold. The images below demonstrate how --flatten_threshold can affect flattening. Notice that the large text is never flattened, only the text occluded by the rectangle.