Easy Tutorial
❮ Prop Nodelist Length Prop Table Tfoot ❯

Style textDecoration Property


Definition and Usage

The textDecoration property sets or returns one or more decorations for text.

Tip: To specify more than one decoration type for elements, use a space-separated list.

Syntax

Setting the textDecoration property:

Returning the textDecoration property:

Value Description
none Default. Defines standard text.
underline Defines a line under the text.
overline Defines a line over the text.
line-through Defines a line through the text.
inherit The value of the textDecoration property is inherited from the parent element.

Browser Support

All major browsers support the textDecoration property.

Note: IE7 and earlier versions do not support the "inherit" value. IE8 only supports "inherit" if the !DOCTYPE is specified. IE9 supports "inherit".


Example

Decorating Text:


❮ Prop Nodelist Length Prop Table Tfoot ❯