Closed Gdesau closed 6 months ago
As far as I understand, it is mandatory for a TTF font to include a ".notdef" glyph (with metrics). This glyph is used in a lot of software when the actually requested glyph is not present in the font (usually displaying as a box, possibly with a question mark or X inside).
Your error message looks like this glyph (specifically: its size information) is missing from your font. If that is indeed the case, then there's little we can do about it, other than maybe produce a more informative error message.
Hi @gmischler, thanks a lot for your quick answer! Maybe it's due to the fact that it's the system version of "Times New Roman" or you think that it doesn't contain this glyph at all?
Apple has some of their own specialities with regards to font file formats. I'm not sure if we have ever systematically tested our code with Apple fonts. It's possible that we might need to do something a little bit differently with those.
Of course, it is also still possible that you're just dealing with a broken font...
Do you have any other request regarding this @Gdesau? Or can this issue be closed?
Hi @Lucas-C, the issue can be closed, thanks @gmischler for your precious help.
Hello everyone, I'm trying to add a unicode Times New Roman font but I get a KeyError. Here is my code:
The function:
The code where I use the function:
And here is the error I get:
My Environment
fpdf2
version used: 2.7.8Does anyone have any idea on how to fix this? It's weird because it was working with the Arial font. Thanks in advance!