A PDF void

TL;DR

There seems to be a big void in Perl PDF generation.

This, or my search-fu needs some refinement.

There’s a few modules that I’d like to fill automatically and I thought that surely there must be some solution using Perl to this regard.

The answer is definitely yes but, to some extent, it is also somehow disappointing.

There are a few giant modules (like standing on the shoulders of the giants, I mean), namely CAM::PDF and PDF::Builder among others. Hence, the area is definitely well guarded.

But it seems that when it comes to managing PDF forms, we can only (easily) leverage on stuff built elsewhere and fill them in. This is disappointing, because I was definitely expecting to be able and add field stuff in PDF pages just like I’m able to add text fragments and shapes.

The closer I’ve come is this post on Perl Monks, which anyway does not start from scratch and makes some assumptions about the structure of a starting PDF:

I’m relying on AcroForm and Annots fields being available. Not too difficult to create them manually, though.

Well, it’s definitely too difficult for me.

So well, there we go: as of today, I haven’t found a programmatic way (in Perl, at least) to generate PDF forms from scratch.

Stay safe!


Comments? Octodon, , GitHub, Reddit, or drop me a line!