B.42. font-style

This property lets you choose between the normal, italic, and oblique styles of a font.

Inherited: Yes

See also: Section B.37font

B.42.1. Value

normal, oblique, or italic.

Initial value: normal

B.42.2. Compatibility

CSS Version: 1

Supported by all CSS-compatible browsers.

Most browsers will artificially skew a normal font to create an italic style if none is available. Additionally, most browsers will treat the oblique setting as a synonym for italic, rather than select or generate an actual oblique font style.

B.42.3. Example

The default style sheets employed by most browsers specify that emphasis (em) elements should be displayed in an italic font. If you wanted to display emphasis with an underline instead, you would ...

Get HTML Utopia: Designing Without Tables Using CSS now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.