Release pdfHTML 4.0.4
Release date: October 25, 2022
pdfHTML is an iText 7 add-on for Java and .NET to create PDF from HTML (and associated CSS).
The big news for this release is the addition of support for CSS4
device-cmyk colors. Until now pdfHTML only supported CSS RGB colors for direct conversion to PDF, although a workaround was possible by using
convertToElements (Java/.NET) rather than
convertToPdf (Java/.NET). However, we decided to add initial support for
device-cmyk following a request from a customer who wanted to make use of this functionality to optimize their workflow.
Note that this functionality is not available out of the box since
device-cmyk is classed as an experimental feature in CSS, and only exists in CSS working drafts. To enable
device-cmyk notation you'll need to change the validation rules with the
CssDeclarationValidationMaster#setValidator static method (Java/.NET) before working with html2pdf. There are currently 2 validators:
CssDefaultValidator – the default validator which uses the previous rules of CSS validation and
CssDeviceCmykAwareValidator – which, as the name suggests does support this experimental feature.
See the example linked below for more details.
Release Related Examples
|iText pdfHTML – 4.0.4 (Java)||link||link||N/A||link|
|iText pdfHTML – 4.0.4 (.NET)||link||N/A||link||link|
- Support for device-cmyk
iText 7: Converting HTML to PDF with pdfHTML
Examples (latest ones)
FAQ (latest ones)