Intent to Implement And Ship: font-variant-numeric

46 views
Skip to first unread message

Dominik Röttsches

unread,
May 6, 2016, 9:01:09 AM5/6/16
to blink-dev

Contact emails

dr...@chromium.org


Spec

https://drafts.csswg.org/css-fonts/#font-variant-numeric-prop


Summary

Our implementation of CSS Fonts Module Level 3 has gaps. Now that font-variant-caps is implemented, I also have successfully turned font-variant from a primitive value property into a shorthand. As an alternative, font-feature-settings is working, but still some of the OpenType font feature selection through CSS value keywords are not implemented. We still miss some of the font-variant subproperties: At the moment we have ligatures & caps. This Intent to Implement and Ship requests to add font-variant-numeric.


Motivation

Using the CSS keywords for feature selection is at candidate recommendation status in the CSS Fonts Module level 3 and is the spec recommended way to activate common features:


"Authors should generally use ‘font-variant’ and its related subproperties whenever possible and only use this property for special cases where its use is the only way of accessing a particular infrequently used font feature."


Signals from content developers and font foundries indicate that the CSS font-variant-* value keywords are easier to work with and less cryptic than font-feature settings. In the case of font-variant-caps, there is also additional fallback/synthesis semantics for fonts that do not have this feature. 


Interoperability and Compatibility Risk

Safari Nightlies and Developer Preview version and Firefox since 34 are shipping the feature.

Edge seems to ship only the low level font-feature-settings selection, but not the keyword implementations.


In my opinion the compatibility risk is low. The spec takes care of resolving some ambiguities between the font-variant: CSS 2.1 settings and and the newer syntax. (See the syntax for font-variant-css21 in the font property shorthand.)


Wherever possible, on Mac these font-variant-* keywords are mapped from OpenType features to the respective features of AAT fonts as good as possible. However, this is outside the scope of Blink and mainly done by our HarfBuzz text shaping library.


Ongoing technical constraints

None


Will this feature be supported on all six Blink platforms (Windows, Mac, Linux, Chrome OS, Android, and Android WebView)?

Yes


Debuggability

Debuggable as usual through the CSS properties inspection panel, where values are autocompleted and can be toggled.


OWP launch tracking bug

https://crbug.com/609813


Link to entry on the feature dashboard

https://www.chromestatus.com/features/5716551491649536


Requesting approval to ship?

Yes

TAMURA, Kent

unread,
May 9, 2016, 3:38:19 AM5/9/16
to Dominik Röttsches, blink-dev
LGTM1
It sounds very low risk.

--
TAMURA Kent
Software Engineer, Google


Dimitri Glazkov

unread,
May 9, 2016, 11:27:00 AM5/9/16
to TAMURA, Kent, Dominik Röttsches, blink-dev
LGTM2

Chris Harrelson

unread,
May 9, 2016, 1:36:26 PM5/9/16
to Dimitri Glazkov, TAMURA, Kent, Dominik Röttsches, blink-dev
LGTM3

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
Reply all
Reply to author
Forward
0 new messages