we (web engine): Experimental web browser project to understand the limits of Claude
2
fork

Configure Feed

Select the types of activity you want to include in your feed.

SVG renders with excessive letter-spacing (huge gaps between glyphs) #196

open opened by pierrelf.com

Found by headless e2e smoke pass. Text inside <svg><text>...</text></svg> renders with extra whitespace between each glyph; the source string "SVG text" appears as "S V G t e x t" with letters spread wide.

Repro#

cargo run -p we-e2e -- --url crates/e2e/pages/12_svg.html --out /tmp/svg.png

See crates/e2e/artifacts/12_svg.png: shapes render correctly; only the text element is broken.

Likely cause#

The SVG text rasterizer advances by glyph metrics + an extra step (possibly conflating em-width with advance, or advancing by the bounding-box width instead of the glyph's horizontal advance metric).

Acceptance#

SVG <text> glyphs are laid out using their horizontal advance metric. The rendered string visually matches normal text rendered through HTML at the same font-size.

sign up or login to add to the discussion
Labels

None yet.

assignee

None yet.

Participants 1
AT URI
at://did:plc:meotu43t6usg4qdwzenk4s2t/sh.tangled.repo.issue/3mlyac4l26s2w