OpenPDF
OpenPDF copied to clipboard
Provide PDF/A conform annotations
Description of the new Feature/Bugfix
It's currently not possible to create annotations which are PDF/A conform. The validation test with VeraPDF fails with this message:
ruleId=RuleId [specification=ISO 19005-1:2005, clause=6.5.3, testNumber=2], status=failed, message=An annotation dictionary shall contain the F key. The F key’s Print flag bit shall be set to 1 and its Hidden, Invisible and NoView flag bits shall be set to 0
Related Issue: #980
Unit-Tests for the new Feature/Bugfix
- [ ] Unit-Tests added to reproduce the bug
- [x] Unit-Tests added to the added feature
Compatibilities Issues
As far as I can tell this does not cause compatibility issues. Would you consider a backport to 1.3.x?
Testing details
Not that I know of.
Thanks in advance for your review / comments
Quality Gate passed
Issues
0 New issues
Measures
0 Security Hotspots
No data about Coverage
No data about Duplication
Any advice on the CodeFactor issue? I already refactored the changes into one method. I don't see how to further reduce the complexity apart from refactoring the existing constructors, which seems to be beyond the scope of this PR
I think the tools are a little too paranoid by now. Still configuring then. CodeFactor is ok.
Further PRs for 1.4 and 1.3 are welcome. Backport should not be a problem.
Will you submit PRs for the other PDF/A issues described in #980? Thank you!
I think the only blocking issue for us was with the annotations (see https://github.com/TIBCOSoftware/jasperreports/issues/410)
For instance calling createXmpMetadata()
already solves a couple of these errors.
But we will keep that in mind and we much appreciate the possibility to submit PRs :+1: