content.md 2.3 KB

Slant (slnt in CSS) is an axis found in some variable fonts. It controls the font file’s slant parameter for oblique styles.

The Google Fonts CSS v2 API defines the axis as:

Default: Min: Max: Step:
0 -90 90 1
![Two side-by-side type specimens of the word phrase “lean-to”, each shown with a variable axis represented beneath as a horizontal slider. The first specimen, with the slider most of the way to the right to represent a higher value on the axis, shows upright forms. The second specimen, with the slider more to the left to represent a low-to-mid value on the axis, shows more slanted forms.](images/thumbnail.svg)
Typeface: Recursive

Oblique characters follow the structure of the upright styles, while italics have a different structure, typically informed by cursive writing. Obliques are not necessarily merely digitally slanted—optical corrections are often made to avoid distortions and an incorrect distribution of weight. Generally, obliques are less common than italics.

For variable fonts, the italic axis and the slant axis are very closely related. For detailed descriptions on how to use both, please see our “Styling type on the web with variable fonts” article.

In line with the current CSS spec, the four-character code for this axis should be referenced in lowercase (as only the five axes registered in the OpenType format specification should appear in lowercase). Also, when using the Google Fonts API, the lowercase axes have to appear first in the URL, followed by the uppercase, each in alphabetical order.