CSS font-style

The CSS font-style property selects between normal (sometimes referred to as “roman” or “upright”), italic and oblique faces within a font family.

CSS property font-style

CSS version: CSS 2.1
Value: normal | italic | oblique | inherit
Initial: normal
Applies to: all elements
Inherited: yes

Example – font-style

In the following code, CSS property font-style can be changed to the following values
  • normal
  • italic
  • oblique
<style type="text/css">
div {
  width: 100px;
  font: 14px/18px sans-serif;
  font-style: normal;
<div>This is sample text to test font-style property</div>
font-style refresh



Share this article: share on Google+ share on facebook share on linkedin tweet this submit to reddit


Click here to write/view comments