fonttools / fontbakery

🧁 A font quality assurance tool for everyone
https://fontbakery.readthedocs.io
Apache License 2.0
554 stars 103 forks source link

New check: Instances on fvar table have postscript names #4587

Open simoncozens opened 8 months ago

simoncozens commented 8 months ago

What needs to be checked?

fvar instances need to have PostScript name entries.

Detailed description of the problem

Notwithstanding the discussion at #3708 in which @miguelsousa says:

Named instances are not required to have PostScript names. However, if one has it, all must have it.

@vv-monsalve has found that if you don't have PostScript names on your instances, you can run into trouble with printing from Adobe applications. (I'm guessing, with no evidence, that use these names to embed fonts into PDFs while printing, and without the names it all goes wrong.)

Resources and steps needed to reproduce the problem

I'm going to leave this for Vivi to weigh in on after some more experiments.

Suggested profile

Suggest which profile the check should be added to. The most common are:

Suggested result

Which log result level should the check have:

Severity assessment

(Classify the problem on a scale of 1 (minor) to 5 (major). How "buggy" would the font be considered if it had the problem described?)

2

vv-monsalve commented 8 months ago

Edit: After further tests performed, the initially mentioned shaping issue doesn't seem to be related to the PS names but rather a GSUB issue on the tested fonts.

vv-monsalve commented 8 months ago

PostScript name length limit

However, after advanced reading and proofs, this seems not to be an issue for PS instance names on Variable Fonts.

Background

This concern stems from Adobe's 29-character length limit on name ID 6 mentioned in #2179

In this Adobe Font Naming Issues PDF, the PostScript name (nameID 6) must have no spaces and be limited to 29 characters for old postscript printers (see page 8).

Where Adobe states:

For compatibility with the earliest version of PostScript interpreters and with the file systems in some operating systems, Adobe limits the number of characters int the FontName to 29 characters.

However, the above document dates from 1993, so it only refers to the FontName. In the specific documentation about these PostScript names for using OpenType font variations it states that the length limit for these names is 127, which differs from the 29-character limit specified for the name ID 6.

doing so is especially recommended when the PostScript name length approaches the 127 character limit.

vv-monsalve commented 8 months ago

Based on the shaping issues, I would suggest including this check in the Universal profile instead.