Style fontStyle Property
Style fontStyle Property
The fontStyle property is used to either set or return the style of the font. The style may be normal, italic, or oblique.
Syntax:-
Its syntax is:- object.style.fontStyle OR object.style.fontStyle = normal|italic|oblique|initial|inherit
Return:-
Its return is:- string having font style of the text in the element
Further Explanation:-
Value | Description |
---|---|
normal | The font is normal. |
italic | The font is italic. |
oblique | The font is oblique. |
initial | Sets property to its default value. |
inherit | Inherits property from its parent element. |