Style textDecorationLine Property

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP







<!--
main_leaderboard, all: [728,90][970,90][320,50][468,60]
-->




Style textDecorationLine Property


❮ Style Object



Example


Display paragraphs with a line on top:



document.getElementById("myP").style.textDecorationLine = "overline";

Try it Yourself »


Definition and Usage


The textDecorationLine property sets or returns what type of line, if any, the decoration will have.


Note: You can also set the textDecorationLine using the textDecoration property,
which is a short-hand property for the textDecorationLine, textDecorationStyle, and the textDecorationColor properties.


Note: You can also combine more than one value, like underline and overline to display lines both under and over the text.



Browser Support














Property
textDecorationLine 57.0 Not supported 36
6.0 Moz
7.0 Webkit 44.0

Syntax


Return the textDecorationLine property:



object.style.textDecorationLine

Set the textDecorationLine property:



object.style.textDecorationLine = "none|underline|overline|line-through|initial|inherit"

Property Values
















Value Description
none Default value. Specifies no line for the text-decoration
underline Specifies that a line will be displayed under the text
overline Specifies that a line will be displayed over the text
line-through Specifies that a line will be displayed through the text
initial Sets this property to its default value. Read about initial
inherit Inherits this property from its parent element. Read about inherit

Technical Details








Default Value: none
Return Value: A String, representing the text-decoration-line property of an element
CSS Version CSS3

Related Pages


CSS reference: text-decoration-line property




❮ Style Object

Popular posts from this blog

Malaysia to Papua New Guinea by motorcycle?

PHP code is not being executed, instead code shows on the page

List of Bhojpuri films