googlefonts / googlefonts/glyphsLib

keys in Glyphs userData{UFO.lib{}} should be exported to root of lib.plist

Open
#230 6 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Python
Stars
201
Forks
56
Avg merge
17m
Merged PRs (30d)
1

Description

When importing a UFO, Glyphs dumps any lib.plist keys it doesn't recognize into userData{UFO.lib{}}. On manual export it then moves those back out of that subkey in to the root of lib.plist. I've confirmed that this is intentional on Glyphs's part. Examples of such keys:

- public.postscriptNames
- any custom keys (such as org.sil.altLineMetrics, org.sil.lcg.transforms)

write_ufo should follow Glyphs's export behaviour and restore these keys to the root of lib.plist instead of leaving them in a UFO.lib key.

This will also help to avoid the problem where a font ends up with two public.postscriptNames keys, a complete one in UFO.lib and a strangely minimal one in the root.

Contributor guide

Open the contributing guide

Research direction

Start at the write_ufo entry point and inspect how imported userData{UFO.lib{}} values are written to lib.plist. Verify the handling of public.postscriptNames and custom keys such as org.sil.altLineMetrics and org.sil.lcg.transforms; done means these keys are restored at the root without leaving duplicate or nested copies.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.