The text decorations are not technically
inherited, but the effect is similar to
inheritance. If they??™re set on an inline
element, they apply to all boxes
generated by that element. If they??™re set
on a block-level element, the setting is
applied to an anonymous inline box that
encompasses all inline children in the
normal flow, and also to all block-level
descendants in the normal flow. The
decorations are not propagated to
floated or absolutely positioned descendants, or to descendant inline tables or inline
blocks.
Example
With the following rules applied, unvisited
anchor links are bold, but have no
underline, visited links have a line through
them, and links in the hover or focus state
have a line above and below them:
a:link {
font-weight: bold;
text-decoration: none;
}
a:visited {
font-weight: bold;
text-decoration: line-through;
}
a:hover, a:focus {
text-decoration: underline
overline;
}
Also, text decorations on inline boxes are rendered along the entire box, even if it
contains descendant boxes.
Pages:
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493