Name

font-family — IE4 Y/Y | IE5 Y/Y | NN4 Y/Y | Op3 Y/-

Synopsis

This is used to declare a specific font to be used, or a generic font family, or both. Note that the use of a specific font family is dependent on the user having said font installed on the system. Thus the use of generic font families is strongly encouraged, since this will cause the user agent to attempt to substitute a similar font.

Example

P {font-family: Helvetica,sans-serif;}

Values

[[<family-name> | <generic-family>],]* [<family-name> | <generic-family>]

Default

UA specific

Inherited

yes

Applies to

all elements

Get Cascading Style Sheets: The Definitive Guide 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.