Skip to content

fix(layers): restore SDF text outlines - #10545

Merged
chrisgervang merged 1 commit into
masterfrom
issue-10274
Aug 11, 2026
Merged

chrisgervang merged 1 commit into
masterfrom
issue-10274

Conversation

@chrisgervang

@chrisgervang chrisgervang commented Aug 11, 2026 •

Copy link
Copy Markdown
Collaborator

Closes #10274

Background

The 9.3 text metrics update wrote padded SDF bitmaps into the font atlas while keeping icon frames restricted to measured glyph bounds, clipping outlines and reducing their perceived height.

Change List

  • Expand renderer-produced glyph frames to the copied bitmap bounds while preserving layout advances and anchors.
  • Add a platform-independent HOgI. SDF outline render case covering straight edges, curves, a descender, a narrow glyph, and punctuation.
  • Validate with the focused and full TextLayer render suites, headless TextLayer tests, lint, and commit hooks.

Note

Medium Risk
Changes font-atlas glyph framing for all custom/renderer-produced glyphs; behavior is localized to text rendering but affects SDF layout and anchors globally for that path.

Overview
Fixes SDF text outlines being clipped after the 9.3 text-metrics change: padded SDF bitmaps were drawn into the atlas but glyph icon frames still matched measured bounds, so halos and outlines were cut off.

In font-atlas-manager, after copying renderer output into the atlas, frames now use the full copied bitmap (x, y, width, height) and anchor offsets are adjusted so horizontal advance and vertical layout stay aligned with the measured glyph.

Adds a platform-independent render test (text-layer-sdf-outline) with a synthetic SDF font renderer and the string HOgI. (edges, curves, descender, narrow glyph, punctuation) plus an outline style, guarded by a golden image.

Reviewed by Cursor Bugbot for commit 4dca294. Bugbot is set up for automated code reviews on this repo. Configure here.

@coveralls

Copy link
Copy Markdown

Coverage Status

coverage: 84.129% (+0.04%) from 84.087% — issue-10274 into master

@chrisgervang
chrisgervang merged commit cc1d519 into master Aug 11, 2026
6 checks passed
@chrisgervang
chrisgervang deleted the issue-10274 branch August 11, 2026 05:01
@chrisgervang chrisgervang added this to the v9.3 patch releases milestone Aug 11, 2026
@akre54 akre54 mentioned this pull request Oct 1, 2026
7 tasks
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.

[Bug] Text display issues since 9.3.x

3 participants