Originally I’d started discussing this on another thread regarding converting a dynamic XFA form to a standard AcroForm but wanted to break out this question I had separately.
I am comparing the outputs for a particular document with both iText
and Aspose.PDF
(version 20.11.0.0
).
Here is the original document:
original.pdf (248.5 KB)
iText
(trial mode) seems to do just fine with this form. It’s a little off of the original, but it is mostly left intact. Here is the iText
version:
output.itext.pdf (201.0 KB)
Aspose.PDF
seems to not handle this form well, particularly with honoring whitespace and such and the fonts seem off. Here is the output from it:
output.aspose.pdf (834.3 KB)
The 2nd page seems to be the biggest offender. I’m not familiar with this form, but it looks like it’s taking available options and dumping (flattening) those to the document as well? Those options appear only if
[x] Denial
is checked (which it is not by default). Here is a screenshot of it.
itext.aspose.differences.jpg (736.8 KB)
Even if it were checked, it doesn’t seem to respect the whitespace of the original document.
Any insight as to what could be happening here would be helpful. Here is a snippet of what I’m doing:
var document = new Document("original.pdf");
document.Form.Type = FormType.Standard;
document.Save("original.aspose.pdf");