pdfChip in a Nutshell

This short chapter will get you up to speed with what pdfChip is and it will introduce the other chapters so that you can decide whether you want to read this introduction from cover to cover or jump to specific chapters instead.

What is it?

pdfChip is a command-line application that implements a highly-optimised HTML + CSS + JavaScript to high-quality PDF converter (with support for more advanced features such as SVG, MathML, barcodes and more). Lets look at that sentence in a little more detail…

HTML + CSS + JavaScript

The input of pdfChip is an HTML file. As any regular HTML file used on the internet, it can use CSS (Cascading Style Sheets) to apply styling and it can use JavaScript to perform all kinds of tasks. Because pdfChip is based on the WebKit HTML rendering engine, it is familiar with modern HTML syntax and is in essence as flexible as a browser in the type of HTML it can handle.

But pdfChip also understands extensions to the HTML and CSS languages which allow it to support features that regular HTML and CSS would not have an answer for; this includes support for pagination, extended color spaces, metadata and much more.

High-quality PDF

The output of pdfChip is a high-quality PDF document. The high-quality aspect means that:

  • the PDF code is highly efficient, so that documents with many thousands of pages can be generated that are still very compact. The conversion engine is optimised so that it doesn't generate unnecessary content and includes elements which are used multiple times only once in the PDF document.
  • the PDF can be generated in such a way that it is immediately usable for publishing, print production, archival and other professional uses. The ISO PDF/X and PDF/A standards are supported, custom metadata can be included, colors can be specified correctly for a wide range of applications etc…

A Command-Line Application

pdfChip does not come with a user-interface. Instead it has to be controlled through its command-line interface (or CLI), either by using it in a terminal or command-prompt window, or by integrating it through scripting or a high-level programming language. With its lack of external dependencies, small footprint and fast operation, this makes pdfChip especially suited for integration in web-based or cloud-based applications where it can be used to turn any information into high-quality PDF for further processing.

How does it work?

With its command-line interface, pdfChip converts an HTML file (which may reference any number of CSS and/or JavaScript files) into a PDF file. The simplest invocation of pdfChip thus becomes:

pdfChip <Path to HTML file> <Path to PDF file>

Assuming in a terminal window you are in the folder where the pdfChip application is installed and in that folder there is also a file called 'index.html', you could convert this HTML file into a PDF by issuing the command:

./pdfChip index.html result.pdf

The tutorial (introduced in the chapter "Learning pdfChip - the Tutorial") contains much more elaborate examples, but the command-line will always remain relatively simple. Of course the real power (and complexity) lies within the HTML file that is converted.

Architecture

Built on WebKit

Because pdfChip converts HTML into equivalent PDF documents, it is built on top of the WebKit rendering engine. WebKit is the name of the open source web browser engine, used for example by Mac OS X and Safari. Because pdfChip is built using the cross-platform QT framework, it uses the QT WebKit variant to do its work.

Normally WebKit interprets HTML and provides output based on the HTML code and any present CSS and JavaScript. In pdfChip the first part of WebKit is used (the part that interprets HTML) but the back-end is replaced by a custom PDF generator which is highly optimised to generate the minimum necessary PDF code.

Extending WebKit

Because the HTML object model is rather limited when seen in the context of professional publishing workflows, print production workflows, or archival workflows, the WebKit implementation in pdfChip has been extended. A variety of additional HTML elements and CSS attributes have been introduced to allow generating PDF objects that cannot be described correctly with standard HTML and CSS. The chapter on “Main Features” describes many of these extensions in principal; the pdfChip Reference Manual details them.

pdfChip also provides extensions around the concept of pagination; HTML (and specifically HTML5) introduce a number of "fixed page size" features, but they are typically not very well implemented and are incomplete. pdfChip supports a much wider set of features through its HTML and CSS extentions and a number of custom JavaScript objects and functions. These too are described in somewhat more detail further in this documentation.

Tell me more!

This pdfChip Introduction gives an overview of pdfChip on a conceptual level, refer to the list below to understand what each chapter explains. But there is also the pdfChip Reference Manual; this separate book contains all of the nitty gritty details you need to use pdfChip in your environment.

  • pdfChip in a Nutshell
    • The chapter you are now reading
  • What pdfChip is Not
    • Knowing what pdfChip is not, is just as important as knowing what it is. This chapter explains what pdfChip should not be used for and highlights some of the limitations you may encounter.
  • The History of pdfChip
    • The origin of pdfChip explains many of the design decisions taken in the product, which in turn will let you use it more efficiently.
  • Main Features
    • A selection of the main features supported by pdfChip.
  • Learning pdfChip - the Tutorial
    • The hardest part of any new product is taking your first steps... Luckily the tutorial was designed to assist you with exactly that. This chapter introduces how you can use the tutorial and what you'll find in it.
  • pdfChip Use Cases
    • So what could pdfChip be used for? It’s far from us to limit your creativity, but this chapter lists a number of possible use cases for the product.
  • Commercial Aspects
    • Because pdfChip supports a wide range of use cases, it comes in a number of different flavors. Each has specific restrictions and this chapter explains the available flavors so that you can make an informed choice.
  • Where to Go from Here?
    • Done with this book? This chapter explains where you can find more information and how to get help if you get stuck either during your evaluation or after having purchased pdfChip.