Clone this wiki locally
Welcome to the PDF Writer library Wiki. It includes all information about using the PDF Writer library.
The PDF Writer library allows you to generate PDF files. It was developed with a principal “one-off” method of generating PDF files. Adhering to this idea it is both fast and retains a low memory signature regardless of how large the file grows. It is therefore ideal for generating small PDF files fitting for exchange scenarios, as well as for generating large file, as is the case for most VDP (Variable Data Publishing) scenarios.
The library has a set of high level features for adding content to a PDF. The high level features supported by the library are:
- Creation of pages.
- Primitives drawing and any of the simple PDF operators for drawing content.
- PDF,JPG and TIFF images embedding.
- Unicode text support with Type1, TrueType and OpenType fonts.
- Defining reusable objects using XObject Forms.
- Modifying PDF files.
- You can also, independently, use the library as a PDF Parser.
To support the requirement for using more sophisticated features the library was made to be very extensible.
It is easy to implement more PDF features by using the lower level set of methods that provide access to the PDF building blocks themselves. Adding a feature requires you to be familiar with the PDF formatting of that feature, but will not require you to write the basic PDF building blocks, as the library handles this.
It is also very extensible for the existing features. For instance, if you want to support more than just Unicode text, it is possible to develop just the mapping between the text to the glyphs, and the library will take care of the rest – namely defining the font, drawing the glyphs etc. Another example – if you want to add more attributes to a page than what is supported – the library provides hooks to adding them at the time the page is written to the file.
For a full list of features and from there to details of each feature go to – Features
and did i mention it’s free?
Now for Some technical details:
- The project is licensed under Apache 2.0. for more information go to Licensing
- The programming language is C++
- It is cross platform
- The library is thread safe, in that you can use multiple instances of it to generate multiple files.
If you want to start using the library , you will find useful build and running instructions here – Building And Running Samples
All relevant project downloads, with the latest release of the library sources, are here
Now for some pointers to the rest of the documentation, with help and samples:
The project has a blog, with some useful how-tos. You can find a list of them here: http://pdfhummus.com/How-To
The solution includes two projects:
1. PDFWriter – The library. go to PDFWriter Project, for discussion of classes, and sort of reference for the high level objects.
2. PDFWriterTestPlayground – Test playground for various classes. i’m doing my unit testing here. created a simple testing mechanism which may be interesting on it’s own. but in any case, it’s a good source for usage samples PDFWriterTestPlayground Project.
Something of note is that the library is using a namespace called PDFHummus for some of its classes, for details on classes defined under this namespace, go here – PDFHummus namespace
Linearized PDF is not supported, check this note – Note on Linearized PDF
In the beginning i wrote a project vision statement. it’s here Project principles
There are several codes or other libraries i’m using for the library, they are all mentioned here – Open Source Source Code and Libraries Usage