-
-
Notifications
You must be signed in to change notification settings - Fork 80
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
New: add more name IDs and make sure the correct settings are fontRev… #86
Conversation
@puzrin please take a look? |
I'd say, project tests should be reorganized with use of Without normal testing it's very difficult to move forward. |
// We must update the fontRevision field and ensure that a specific string is | ||
// supported. See also: https://silnrsi.github.io/FDBP/en-US/Versioning.html | ||
font.revision = fontVersion[3]; // Only number | ||
|
||
font.sfntNames.push({ id: 5, value: versionString }); // version ID for TTF name table | ||
font.sfntNames.push({ id: 6, value: (options.fullname || svgFont.id).replace(/[\s\(\)\[\]<>%\/]/g, '').substr(0, 62) }); // Postscript name for the font, required for OSX Font Book |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In name id 5, the minor version should always be three digits and should refer to the UFO specification(openTypeNameVersion): https://unifiedfontobject.org/versions/ufo3/fontinfo.plist/#opentype-name-table-fields,I can also consider adding openTypeNameUniqueID
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In the implementation of ufo2ft, the default version is always 0.000. Use Python's .zfill(3)
to fill 0 in front of the minor version, similar to .padStart(3, '0')
in JS.
…ision and version
42491d6
to
7261bc0
Compare
IMO this is not enough flexible and should be reworked.
|
@yisibl here are 2 PRs and 1 issue i'd like to close/replace: #86, #102, #105. Reason: topics were mutated multiple time, and tend to be "endless". My last opinion #86 (comment) is to create 2 new issues if that's still actual. AFAIK, all other critical things have been landed to master. Let me know what you think. |
I'm very sorry for the late reply. When I have time, I will investigate how the APIs of other libraries are handled. You can close these issues first. Thanks! |
fontRevision
It is no longer always1.0
.Based on the recommendations[1] in this document, we can now support better version number settings. It can be displayed correctly in the font editing software.
e.g.
Version 5.678 beta3
TODO: add test cases.
[1] https://silnrsi.github.io/FDBP/en-US/Versioning.html