-
Notifications
You must be signed in to change notification settings - Fork 599
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
make CIDSet generation optional again for TrueTypeFontUnicode (subset = true) #1041
Comments
@bsanchezb May you investigate this please? |
Hi, Our scenario is that an end-user provides a document and wants it to be signed with a visual electronic signature. The initial document format is not known, but the signature creation tool should be able to keep PDF/A conformance when possible. The PR #815 keeps the conformance by default, while also adding CIDSet for other document types, when font is used. But it does not break conformance for those documents neither. I see that @zyro23 sees this information as redundant in their case. The only alternative option I can see, because OpenPdf is not capable of identifying PDF/A type of the document, is to add a separate boolean variable, something like "includeCIDSet", which may be used to explicitly modify the behavior of the CIDSet creation, instead of using "subset". Or we can even use "subset && includeCIDSet" in order to include the CIDSet. I would keep the value of "includeCIDSet" as TRUE by default, as this will protect users from breaking PDF/A-1 conformant documents. KR, |
completed? i think the reasoning for an additional boolean flag makes sense (being used instead of i can come up with a pr and would make the flag accessible via sounds ok? if so, please re-open. |
Please submit a pull request, thank you. |
… publicly accessible (LibrePDF#1041)
Is your feature request related to a problem? Please describe.
#815 (release 1.3.31) added generating a CIDSet for
TrueTypeFontUnicode
ifsubset
istrue
:however, the referenced PDF/A-1 validation rule (6.3.5-3) is not required for PDF/A version 2 and 3 compliance.
a pdf without CIDSet streams that contains only a subset of the used fonts validates fine with PDF/A versions 2 and 3.
but if a CIDSet is present, all CIDs of the font have to be present which means effectively the complete font being embedded:
Describe the solution you'd like
please allow to opt out of CIDSet generation for
TrueTypeFontUnicode
(Identity-H
,embedded
=true
,subset
=true
) again.Describe alternatives you've considered
PdfWriter.pdfxConformance
has no effect because thesubset
check takes precedence (see referenced pr)subset = false
"works" but is no viable option - that results in pdf file size differences of megabytes instead of a few kb because the complete fonts are embeddedAdditional context
versions up to 1.3.30 are working fine.
thank you!
The text was updated successfully, but these errors were encountered: