Skip to content

css: Inherit font variations and features from settings

Matthias Clasen requested to merge css-font-features-variations into main

Compute the initial values of the font-feature-settings and
font-variation-settings CSS properties from the system default
font.

This has the same effect as if we had a @font-face rule in CSS
that combined the family, variations and features of the system
default font into a face that is then used by our CSS as the
initial font.

This makes it a lot easier to use a font with specific combinations
of features as default, without having to resort to 'customizer'
scripts that rewrite the font file and 'freeze' features.

Merge request reports

Loading