Skip to content
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

Unable to load newer fonts in Zend_Pdf #439

Open
colorninja opened this issue Sep 20, 2024 · 0 comments
Open

Unable to load newer fonts in Zend_Pdf #439

colorninja opened this issue Sep 20, 2024 · 0 comments

Comments

@colorninja
Copy link

colorninja commented Sep 20, 2024

If you try to load a newer font using Zend_Pdf, you get an error Unable to read version 4 table. The check is done at:

/library/Zend/Pdf/FileParser/Font/OpenType.php:555

This is because newer fonts use OS/2 table version 4, which is similar to 3. There are no structural differences between OS/2 v3 and OS/2 v4. Changing the value on the if statement will make fonts work most of the time. There are some specification differences, although and I can't find any information on how they differ.

I am trying to use the font Inter in my PDFs.

I've searched for a way to convert from v4 to v3 but can't find any easy way to do so. Would it be hard to implement this change?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant