W3C home > Mailing lists > Public > www-style@w3.org > April 2011

RE: [css3-text] Underlines match the color of the text (was Allow control of text-decoration width

From: Eric A. Meyer <eric@meyerweb.com>
Date: Fri, 8 Apr 2011 17:05:07 -0400
Message-Id: <a06230904c9c5283dbbbb@[10.244.56.163]>
To: www-style@w3.org
At 01:29 -0400 4/8/11, Koji Ishii wrote:

>I understand there's a compatibility issue. But if matching 
>underline colors to the color of text is oftentimes desired 
>behavior, we could add another value to avoid compatibility issues 
>like this:
>
>   text-decoration-color: textColor
>
>I'm not sure if it's important enough to justify the cost, but both 
>Word and In Design behaving so makes me believe it is more common 
>than CSS 2.1 way.

    Here's a current workaround:

      * {text-decoration: inherit;}

WARNING: this may have unintended consequences in scenarios I haven't 
envisioned, and it can't really cover cases where a child has a 
decoration different than its parent's decoration and you want both 
decorations in the child's area to be the same color as the child.
    Still, it should cause any element with a parent that's been 
text-decorated to copy the decoration onto itself, and thus set the 
color of its new self-decoration to its own color.

-- 
Eric A. Meyer (eric@meyerweb.com)     http://meyerweb.com/
Received on Friday, 8 April 2011 21:05:34 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:39 GMT