HTML DOM Style textDecorationLine property
Examples
At the top of the paragraph a line appears:
try it"
Definition and Usage
textDecorationLine property sets or returns modified text line type to use.
Note: You can also use textDecoration property set textDecorationLine. textDecoration property is textDecorationLine, textDecorationStyle and textDecorationColor properties shorthand property.
Note: You can also use multiple values simultaneously, such as underline and overline, to show the lines above and below the text.
Browser Support
Almost all of the major browsers do not support textDecorationLine property.
Firefox supports another alternative of the property attribute that MozTextDecorationLine property.
grammar
Back textDecorationLine properties:
Setting textDecorationLine properties:
Property Value
值 | 描述 |
---|---|
none | 默认值。规定文本修饰没有线条。 |
underline | 规定文本的下方将显示一条线。 |
overline | 规定文本的上方将显示一条线。 |
line-through | 规定文本的中间将显示一条线。 |
initial | 设置该属性为它的默认值。请参阅 initial 。 |
inherit | 从父元素继承该属性。请参阅 inherit 。 |
technical details
Defaults: | none |
---|---|
return value: | String representing the text-decoration-line attributes of the element. |
CSS version | CSS3 |
related articles
CSS Reference: text-Decoration-Line Properties