New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement the font-optical-sizing property #19058
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Already reviewed downstream.
0c5fe66
to
c5d8853
Compare
CC @jfkthame - I was trying this test in Firefox release and nightly: In Nightly the font does not get loaded - why might that be? In Release (on Mac) |
CC @emilio ^^ is what we discussed here at TPAC, thanks for taking a look! |
Poking a bit it seems like the sanitizer is rejecting it:
But I think we should log a message to the console or so in that case. |
Ah, the message goes to the console, but it goes to the "CSS" category, which is disabled by default. |
Thanks, managed to fix the font to pass OTS, had a wrong name id for the new axis name as well as a missing axis filter entry in the variations store in GDEF. Thanks for the CSS button tip. |
c5d8853
to
698b027
Compare
698b027 should contain the updated font. Thanks for your help @emilio . |
0da86f5
to
a0e247e
Compare
Implement the CSS fonts property font-optical-sizing [1]. Typographic optical sizing means that a font has slight variations in glyph contrast to better optimize for legibility at different font sizes: The glyph shapes vary between for example a headline font size and a body text font size. The CSS font-optical-sizing property with its default value of auto exists to automatically apply the current font size value to a variable font's 'opsz' axis. This means, if a variable font supports the 'opsz' axis and optical sizing, the right value is automatically applied without the need for an explicit font-variation-settings styling. Intend to implement and ship: https://groups.google.com/a/chromium.org/forum/#!topic/blink-dev/Y3lhEykjfV0 Chromestatus entry: https://www.chromestatus.com/feature/5685958032752640 [1] https://drafts.csswg.org/css-fonts-4/#font-optical-sizing-def Bug: 773697 Change-Id: Ifa4b6e042204a3fbf172b8cfe232821d8691283b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1795244 Commit-Queue: Dominik Röttsches <drott@chromium.org> Reviewed-by: Robert Sesek <rsesek@chromium.org> Reviewed-by: Koji Ishii <kojii@chromium.org> Reviewed-by: Emil A Eklund <eae@chromium.org> Reviewed-by: Chris Harrelson <chrishtr@chromium.org> Cr-Commit-Position: refs/heads/master@{#697197}
a0e247e
to
cd8ae6c
Compare
Implement the CSS fonts property font-optical-sizing [1]. Typographic
optical sizing means that a font has slight variations in glyph contrast
to better optimize for legibility at different font sizes: The glyph
shapes vary between for example a headline font size and a body text
font size. The CSS font-optical-sizing property with its default value
of auto exists to automatically apply the current font size value to a
variable font's 'opsz' axis. This means, if a variable font supports the
'opsz' axis and optical sizing, the right value is automatically applied
without the need for an explicit font-variation-settings styling.
Intend to implement and ship:
https://groups.google.com/a/chromium.org/forum/#!topic/blink-dev/Y3lhEykjfV0
Chromestatus entry:
https://www.chromestatus.com/feature/5685958032752640
[1] https://drafts.csswg.org/css-fonts-4/#font-optical-sizing-def
Bug: 773697
Change-Id: Ifa4b6e042204a3fbf172b8cfe232821d8691283b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1795244
Commit-Queue: Dominik Röttsches <drott@chromium.org>
Reviewed-by: Robert Sesek <rsesek@chromium.org>
Reviewed-by: Koji Ishii <kojii@chromium.org>
Reviewed-by: Emil A Eklund <eae@chromium.org>
Reviewed-by: Chris Harrelson <chrishtr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#697197}