Apache Batik SVG plugin control

PD4ML implements its own basic SVG renderer, and also allows you to use third-party libraries for the task. If it finds Apache Batik SVG Toolkit among the available libraries, it will automatically switch to it.

Batik tries to implement most of the features of SVG. But, unfortunately, it is very sensitive to even minor file format errors, and there is no way to change its error policy: it always throws exceptions, and there is no switch to turn them into warnings, for example.

In such cases, the best workaround would be to disable Batik and let the built-in SVG engine do the rendering.

Java code to disable Batik:

com.pd4ml.plugins.BatikSvgCustomTag.disable = true;

Disable in pd4browser.properties:


CSS Flexible Box Layout support added

PD4ML v4.0.6 introduces flexbox layout support.

Children of a flex container can “flex” their sizes, either growing to fill unused space or shrinking to avoid overflowing the parent. Both horizontal and vertical alignment of the children is supported.

Automatic Font Kerning Support

PD4ML v4.0.4 introduces optional font kerning support. Kerning is an addition or reduction of space between two characters (glyphs) of a proportional font. As a rule a rendered text is visually much more pleasing when the kerning is applied.

PD4ML uses kerning pairs info from TTF/OTF fonts (if available). For the standard built-in Type1 fonts the kerning info is known and included to PD4ML product itself.

The feature is also implemented in our older development branch v3.11.0 due to its importance

RTF Output Performance

The recent PD4ML builds (both v3 and v4) refactor RTF output logic to improve conversion performance by bulky input HTML documents.

Now, even in extreme situations, the performance is comparable with PDF output and very often outperforms it.









CSS Transform Property Supported

PD4ML v4.0.3 implements CSS transform feature e.g. to rotate, scale, skew HTML objects.

Here is a list of supported transform functions:

  • translate(x, y)
  • translatex(x)
  • translatey(y)
  • skew(x-angle,y-angle)
  • skewx(x-angle)
  • skewy(y-angle)
  • scale(x,y)
  • scalex(x)
  • scaley(y)
  • matrix(n,n,n,n,n,n)
  • rotate(angle)
  • rotatez(angle)