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

Re: [css3-text] Adjacent and nested underlines (was Allow control of text-decoration width

From: Aryeh Gregor <Simetrical+w3c@gmail.com>
Date: Fri, 15 Apr 2011 12:39:47 -0400
Message-ID: <BANLkTik0ysj-tKSuYwyuz7U4m+zJbxx6yA@mail.gmail.com>
To: Koji Ishii <kojiishi@gluesoft.co.jp>
Cc: fantasai <fantasai.lists@inkedblade.net>, "www-style@w3.org" <www-style@w3.org>
On Thu, Apr 14, 2011 at 11:27 AM, Koji Ishii <kojiishi@gluesoft.co.jp> wrote:
> You could do this:
>  .nu { text-decoration: cancel-underline; }
>  <u><span id=x><span class="nu">foo</span>bar</span>baz</u>

Ah, I see.  That wouldn't be backward-compatible, though, so it
wouldn't be useful in WYSIWYG editors today -- even if the markup is
being produced by a fancy advanced browser that supports
cancel-underline, it still needs to be viewable properly if it's given
to a browser that doesn't support cancel-underline.  But in the
long-term it could be workable, although the markup is long.

> I was thinking, in your example, underlines for "bar" and "baz" will not match if they have different font and/or size if implementation is font/size aware, but then I figured out that fantasai's last proposal[1] would solve the case as well. That's nice, I think we should take that.

At this point, I think fantasai's proposal is fine for my purposes, if
we drop the requirement about gaps being left between adjacent
underlines.  Hopefully we can get a response from another implementer
or two within a few days so we know whether that requirement is

The edge case with superscripts still won't work quite right, but it's
an edge case.  If we really need to fix it we can usually do so by
rearranging the markup, and if we can't do that, in the long term we
could use cancel-underline.  So I'm not really worried, especially
since we have so little interop today anyway on such edge cases.
Received on Friday, 15 April 2011 16:40:38 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:38:45 UTC