head table bounding box is not recalculated for variable font instances
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 56/100
Research direction
Start by reading subset_with_variations() and the code that writes the OpenType head table; the issue does not name files or tests. Check how the default instance's bounds are copied and whether existing variation tests cover the table. Done means the instantiated font's xMin, yMin, xMax, and yMax include its glyph bounds, preventing macOS rasterizer cropping.
Written by the indexing model from the issue text.
Description
Using subset_with_variations() to instance of a variable font, it does not update the head table bounds (xMin, yMin, xMax and yMax are copied unchanged). Some glyphs in the instance might be bigger than the bounds of the default instance.
The macOS rasterizer crops glyphs outside of the head bounds. This can be seen when opening PDFs created with Krilla in macOS Preview (I had the same issue in PDFs created with Illustrator previously).
- Dominant language
- Rust
- Stars
- 61
- Forks
- 16
- PR merge metrics
- No merged PRs in 30d
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from typst/subsetter
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 83/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
-
Difficulty 5/5 Over a week Newbie friendliness 45/100
-
Difficulty 3/5 Half a day Newbie friendliness 67/100
Similar issues
-
good first issue help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 80/100
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
swc-project/swc-ai-issues#907 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 62/100
-
area:helper kind:bug priority:p3 ready
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 1 day
-
bug UI
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
wardian-app/Wardian#1746 ·
Maintainers usually reply within 1 day