Closed Bug 1561352 Opened 6 years ago Closed 6 years ago

viewBox-scaling-text-001.html needs changes to correctly reference Ahem font in other browsers

Categories

(Core :: SVG, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla69
Tracking Status
firefox69 --- fixed

People

(Reporter: dholbert, Assigned: dholbert)

References

Details

Attachments

(1 file)

I added a new reftest-style web-platform-test "viewBox-scaling-text-001.html" in bug 1544432, but apparently it fails on other browsers:
https://wpt.fyi/results/svg/coordinate-systems/viewBox-scaling-text-001.html?run_id=266890006&run_id=239240001&run_id=262730005&run_id=241080002

In particular, the testcase is rendering an "X" character instead of an Ahem block-glyph, so the font usage isn't getting picked up.

I'm probably missing some annotation/reference to pull in the Ahem font...

Depends on: 1544432

Ah -- so it looks like technically I am supposed to use fonts/ahem.css and/or <meta flags="ahem">. But that doesn't fix the issue.

The real problem here is that Ahem doesn't have a "X̂̂̂̂̂̂" character, so Chrome/Safari/Edge seem to use a fallback font to provide that character instead. (whereas Firefox happily synthesizes an ahem-block-with-hats character)

So, I need to rewrite this test a bit. I might just morph it into a "mismatch" test, saying that a monospace X̂̂̂̂̂̂ character should look different from a blank page (i.e. it should render something).

(In reply to Daniel Holbert [:dholbert] from comment #1)

So, I need to rewrite this test a bit. I might just morph it into a "mismatch" test, saying that a monospace X̂̂̂̂̂̂ character should look different from a blank page (i.e. it should render something).

Actually, I can still do a "match" test, comparing a scaled-up 1px-viewBox-with-1px-font character against a natural-100px-viewPort-and-100px-font character.

Patch coming up.

Pushed by dholbert@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/66cb2acf5a9e Rewrite WPT test viewBox-scaling-text-001.html to not depend on Ahem font having X-with-diacritics character. r=longsonr
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/17506 for changes under testing/web-platform/tests
Upstream web-platform-tests status checks passed, PR will merge once commit reaches central.
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla69

Looks like this did the trick.

wpt.fyi shows all browsers passing the test now, except Safari which has a single fuzzy pixel in the "elbow" of a serif on the X character.
https://wpt.fyi/results/svg/coordinate-systems/viewBox-scaling-text-001.html?run_id=264950003&run_id=244960018&run_id=255520003&run_id=241100006

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: