Forum How do I...?

Diagnose TTF fonts

mrwarper
I am a big fan of default font families and sizes, but some time (years) ago, I developed a couple of minimal TTF fonts to do some fancy initial caps stuff, and everything worked -- PostScript / PDF printing from Mozillas included the fonts and they displayed just fine.

Yesterday I tried Prince on documents using one of these fonts, and it gives a warning that it "does not allow font embedding", and the font is not embedded in the resulting PDF (surprise!).

Then I installed a modern Mozilla on that machine to check, and more WTF ensued: the fancy font does not display, and the 'error console' reads: "downloadable font: downloaded failed (font-family: "Valenciana 70" style:normal weight:normal stretch:normal src index:0): status=2147500037 source: file:///[...].ttf" (which is the right location of the font file -- it is found and choked on too).

Sure as hell, I checked and my 'old' 2013 Mozilla still works fine with the very same docs and fonts.

Of course, I understand this is not a Prince-only issue, but rather one in fontconfig (or whatever component handles that both in Mozilla and Prince), or maybe another fun instance of something being deprecated and not documented (I've seen a few of those in the past), but I thought someone around here might know what to check for, or what programs can be used to fix them fonts.

I am attaching the offending font (some 20 capital letters in all) just in case someone wants to try it out.
  1. Valen70.ttf10.0 kB
mrwarper
Self-reply: it seems my fonts did have an 'embeddable: no' flag in them indeed. It could be argued this is my own fault, but the venerable old program I use to create them doesn't even have an option for that when generating the final TTF files -- and you can guess what the fixed default value is.

Anyway, I found a much newer utility (from 2001!) that will happily toggle the embeddable flag, so Prince is happy about that and obliges with the font use/inclusion now. It is here: TTF Patch.

However, the new Mozilla above still chokes on the patched file with the same error :/
mikeday
Not sure what is going on here, FontForge seems to think it's okay.

Perhaps it's a file origin issue as described here?
mrwarper
Exactly -- the same Mozilla displayed everything OK when the files were loaded through a local web server I set up for checking :/

Thank you!