PDF Association logo

Discover pdfa.org

Key resources

Get involved

How do you find the right PDF technology vendor?
Use the Solution Agent to ask the entire PDF communuity!
The PDF Association celebrates its members’ public statements
of support
for ISO-standardized PDF technology.

Member Area

Illustration of negative dash phase.

“PDF Differences” GitHub repository is now public

PDF developers everywhere have a new resource; targeted test cases highlighting differences between implementations.
About the author: Peter Wyatt is the PDF Association’s CTO and an independent technology consultant with deep file format and parsing expertise. A developer and researcher working on PDF technologies for more than … Read more
Peter Wyatt

Peter Wyatt
September 22, 2023


Print Friendly, PDF & Email


As announced on May 13, PDF developers everywhere have a new resource; targeted test cases highlighting differences between implementations, including in-depth technical explanations.

The first set of such “parser differential” test-cases became public on September 22, 2023, allowing the full PDF ecosystem - PDF Association members and non-members alike - to align. 

The PDF files provided are for PDF software developers needing minimal targeted test files that demonstrate specific issues that were resolved in the most recent edition of the PDF specification (the latest definition is now available at no cost). These cases are included because they have been observed across multiple widely-used implementations.

Similar to the “responsible reporting” process used in cybersecurity these test cases are previewed to PDF Association members for 60 days prior to open publication. Please note that the PDF Differences repo will not include security-related issues, but focuses exclusively on PDF's "prime directive": portability and interoperability.

Here are three examples from the initial set of eight differences posted to the PDF Differences repo as of September 22, 2023.

Z-order differences in painting operations

In PDF, “fill and stroking” painting operations are explicitly defined to be atomic. This differs from some other graphic languages where similar features are a short-hand convenience for performing a sequence of independent paint operations, commonly "fill then stroke" (e.g. SVG) or occasionally, "stroke then fill".

In these alternate rendering models, and unlike PDF, there is a clear Z-order difference between the fill and stroke objects as illustrated below. In PDF the atomic “fill and stroke” paint operation means that there is never a distinct band where the stoke overlaps the fill area - the lower figures in this diagram are thus incorrect:

Incorrect appearance

 Two stars with colored fill and stroke demonstrating incorrect compositing.

Correct appearance

Two stars with colored fill and stroke demonstrating correct compositing.

Negative dash phase

Prior to ISO 32000-2, the definition of PDF dashing failed to define how to render a negative dash phase, resulting in different appearances between implementations. This is now resolved with new wording in ISO 32000-2.

Illustration of negative dash phase showing a possible result with PDF 1.0 - 1.7 and PDF 2.0-conforming dash phase.

ColorBurn & ColorDodge

The formulae for the ColorBurn and ColorDodge blend modes were corrected by Adobe back in 2009 but missed the publication of PDF 1.7 (ISO 32000-1:2008). These subtle corrections produce the same results except in one special edge case to ensure that the result is a continuous function of the source color cs:

Screen-shot of the table defining ColorBurn and ColorDodge keys.

About the PDF Differences process

The PDF Association uses a private member-only GitHub repo allowing its members to test and address any potential implementation issues within a fixed but reasonable 60 day timeframe before the test cases are moved to the public repo. Implementations at fault will not be named or identified. 

Members wishing access to the members-only pdf-differences-preview repo can add their GitHub user name to their PDF Association member profile via the Member Area on pdfa.org.

WordPress Cookie Notice by Real Cookie Banner