Skip to content

Copy name IDs in use before scrapping or scrambling them for webfonts #3853

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

Merged
merged 8 commits into from
Jun 6, 2025

Conversation

madig
Copy link
Collaborator

@madig madig commented Jun 2, 2025

Preserve select nameIDs in fvar and STAT when obfuscating names, to avoid dangling name IDs in subset fonts.

Closes #3773.

@madig
Copy link
Collaborator Author

madig commented Jun 4, 2025

Hm, how to get CPAL labels and the feat table into a test font?

@anthrotype
Copy link
Member

colorLib.buildCPAL can build palette labels, there's a bunch of tests in Tests/colorLib/builder_test.py, e.g.

def test_build_CPAL_v1_labels():

as to feat, it's defined in otData.py and it doesn't look like we test it anywhere..

@madig
Copy link
Collaborator Author

madig commented Jun 5, 2025

I limited the test to STAT, fvar, ss and cv feature names and CPAL labels for now.

@madig madig marked this pull request as ready for review June 5, 2025 10:49
@madig madig force-pushed the better-handle-name-id-deletion branch from 04a70d4 to 1280acb Compare June 5, 2025 10:53
@madig madig force-pushed the better-handle-name-id-deletion branch from 3267eb8 to d563e04 Compare June 5, 2025 13:47
@anthrotype anthrotype force-pushed the better-handle-name-id-deletion branch from 9e61e2a to 75676f5 Compare June 6, 2025 09:26
@anthrotype anthrotype merged commit 8cd664d into main Jun 6, 2025
11 checks passed
@anthrotype anthrotype deleted the better-handle-name-id-deletion branch June 6, 2025 09:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[subset] --obfuscate-names can drop or scramble names used outside of the name table
2 participants