You are here: Reference > CSS > properties > font-style

font-style property

Browser support:
Specifies whether the style of the font is normal, italic or oblique.
JavaScript page for this property: fontStyle. You can find other example(s) there.

Possible values:

 One of the following values: 
inherit
Takes the value of this property from the computed style of the parent element.
italic
Font should be displayed in italic.
normal
Default. Font is normal.
oblique
Font should be displayed in oblique.
Default: normal.

Example HTML code 1:

This example illustrates the use of the font-style property:
<head>
    <style>
        .normal {
            font-style: normal;
        }
        .italic {
            font-style: italic;
        }
    </style>
</head>
<body>
    <span class="normal">font-style: normal</span><br />
    <span class="italic">font-style: italic</span>
</body>
Did you find this example helpful? yes no

Supported by tags:

Related pages:

External links:

User Contributed Comments

Post Content

Post Content