property
text-decoration — CSS reference
Shorthand for line, style, color and thickness. Not inherited, but decoration propagates through certain descendants. Setting a descendant to none does not erase an ancestor underline.
Formal Syntax & Structure
css syntaxcss
<text-decoration-line> || <text-decoration-style> || <text-decoration-color> || <text-decoration-thickness>Working Example
Example Snippetcss
<!doctype html><html lang="en"><meta charset="utf-8"><title>CSS text lab</title><style>body {margin:0} .sample {background:#dcebe9;color:#182e32}
#a{text-decoration:underline solid red 2px}</style><body><p id="a">Design readable interfaces with CSS.</p><p lang="fa" dir="rtl">متن فارسی برای آزمایش چیدمان</p></body></html>