CSS text-decoration-line property

The CSS text-decoration-line property is used to specify the type of the text-decoration to be applied to an HTML element..

CSS text-decoration-line property

text-decoration-line

The text-decoration-line property is used to specify the type of the text-decoration to be used. It can have the following values:

Values

ValueDefinition
overlineDisplays a line over the text.
underlineDisplays an underlne for the text
line-throughDisplays a line through the text

This is an underlined text.

Example

<p style="text-decoration-line:overline">Text overline</p>
<p style="text-decoration-line:underline">Text underline</p>
<p style="text-decoration-line:line-through">Text line-through</p>

Output

Text overline

Text underline

Text line-through

You can also use the shorthand text-decoration property instead.


Share Tweet Send
0 Comments
Loading...