[wpt-sync] Sync PR 29078 - [a11y] System font sizes should obey user's font size setting
Categories
(Core :: Layout: Text and Fonts, task, P4)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox90 | --- | fixed |
People
(Reporter: wpt-sync, Unassigned)
References
()
Details
(Whiteboard: [wptsync downstream])
Sync web-platform-tests PR 29078 into mozilla-central (this bug is closed when the sync is complete).
PR: https://github.com/web-platform-tests/wpt/pull/29078
Details from upstream follow.
b'Oriol Brufau <obrufau@igalia.com>' wrote:
[a11y] System font sizes should obey user's font size setting
Some form controls get assigned a system font in UA origin:
input, textarea, select, button {
font: -webkit-small-control;
}The font size of that is supposed to be 2pt smaller than the default
font size. However, that "default" was hardcoded to 16px, without taking
into account that the user can change the actual default.For example, someone with suboptimal vision may use a bigger default in
order to be able to read the text with ease. But form controls would
ignore that preference. This was bad for accessibility.So this patch uses the actual default size when calculating the size
of system fonts.Doing so requires a Document from which to retrieve the settings, but
CSSParserContext::GetDocument() is null for UA stylesheets. Therefore,
instead of resolving at parse time, the font longhands are set to a
CSSPendingSystemFontValue, and their resolution is deferred until
computed-value time, when we can use StyleResolverState::GetDocument().Bug: 1054031
TEST=StyleEngineTest.SystemFontsObeyDefaultFontSize
TEST=external/wpt/css/css-fonts/system-fonts-serialization.tentative.html
TEST=fast/css/font-shorthand.htmlChange-Id: I5e9b41a2baa45cea7f1a54190bf593e025153adb
Reviewed-on: https://chromium-review.googlesource.com/2891582
WPT-Export-Revision: 82f8879abfdea33dbd0752e36977006d02332a9d
| Assignee | ||
Updated•4 years ago
|
| Assignee | ||
Comment 1•4 years ago
|
||
| Assignee | ||
Comment 2•4 years ago
|
||
| Assignee | ||
Comment 3•4 years ago
|
||
CI Results
Ran 15 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI
Total 1 tests and 9 subtests
Status Summary
Firefox
OK : 1
FAIL: 6
Chrome
OK : 1
FAIL: 9
Safari
OK : 1
FAIL: 9
Links
Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base
Details
New Tests That Don't Pass
/css/css-fonts/system-fonts-serialization.tentative.html
caption: FAIL (Chrome: FAIL, Safari: FAIL)
icon: FAIL (Chrome: FAIL, Safari: FAIL)
menu: FAIL (Chrome: FAIL, Safari: FAIL)
message-box: FAIL (Chrome: FAIL, Safari: FAIL)
small-caption: FAIL (Chrome: FAIL, Safari: FAIL)
status-bar: FAIL (Chrome: FAIL, Safari: FAIL)
Comment 7•4 years ago
|
||
| bugherder | ||
https://hg.mozilla.org/mozilla-central/rev/8d580564c600
https://hg.mozilla.org/mozilla-central/rev/da5eed1cfca7
Description
•