dferguso/MapSAR_Ex — pull request #3 by emenendez (2013-12-30 04:05:05+00:00)
Title: Generate flattened .pdf from .fdf

Here is one proposal for modifications to the TAF generation process. The real challenge I've been running into printing TAFs was not so much .fdf vs .pdf, but Acrobat doesn't want to combine any files with form data, requiring the TAFs to be printed one-by-one instead of combining into one multi-page .pdf and printing all at once like you can do with the generated maps.

By calling pdftk with both flatten and drop_xfa arguments I got it to output a filled, flattened .pdf from the original TAF form and the generated .fdf. pdftk is licensed under the GPL so I believe it's OK to distribute with IGT4SAR.

This pull request also moves the .fdf generation into a separate module so None types and newlines can be converted in one place, and form field values can be escaped in case of any special characters.

Thoughts and criticisms appreciated :)