On 04.02.2025 22:13, luca boncompagni wrote:
I think that in that way I have a double copy of the Montserrat-Regular.
Is it possible to fill the charwidth array with the correct size or
read the char width from the fullEmbed font?
No, for several reasons: The one downloaded is not the same font. Yours
is smaller and is also missing the TrueType "post" table so I can't open
your font with PDType0Font.load(). I could of course open the downloaded
font that way and move the widths table but I expect more troubles
because it's a different amount of glyphs. I believe your font is
actually a subset, but poorly done by the creator of that PDF ("This is
LuaHBTeX, Version 1.18.0 (TeX Live 2025/dev/Debian)"). The font in the
page content stream shouldn't be the same as the one in the acroform
default resources. The font is not only missing the widths, it is also
missing entries in the /ToUnicode stream which means that this would
have to be fixed as well.
Btw one indicator that the original file is broken is that Adobe claims
that the file has been modified when one opens it and closes it. I don't
know what it is complaining about, maybe a different issue.
Tilman
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: users-h...@pdfbox.apache.org