Bug 174031
| Summary: | Safari always assumes mono-spaced square characters when loading fonts | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Dima Voytenko <dvoytenko> |
| Component: | CSS | Assignee: | Nobody <webkit-unassigned> |
| Status: | RESOLVED FIXED | ||
| Severity: | Normal | CC: | mmaxfield, webkit-bug-importer |
| Priority: | P2 | Keywords: | InRadar |
| Version: | Safari 10 | ||
| Hardware: | All | ||
| OS: | All | ||
Dima Voytenko
See example: http://output.jsbin.com/jexixam/quiet
Initially, before the "Slow" font-face has been loaded or timed out, the sample text takes about 2.5-3x more space to layout (on iOS, it takes about 8-9 lines and once the font is loaded/timed out, it takes only 3 lines). In other words, the estimate is too rough.
It appears that Safari assumes mono-wide square characters, which is very uncommon. It might be a better option to use a fallback font to estimate character layout before the desired font is loaded (as in `font-family: Slow, Arial` where "Arial" is already available as the fallback). This would also reduce the work the browser has to do in case of timeout.
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Radar WebKit Bug Importer
<rdar://problem/33083545>
Myles C. Maxfield
I think I fixed this in r216944. Can you see if the problem still reproduces on a nightly build?
Dima Voytenko
Does appear to be fixed in nightly. Thanks for the fix!