W3C home > Mailing lists > Public > whatwg@whatwg.org > May 2011

[whatwg] Interaction of <wbr> and CSS white-space

From: Boris Zbarsky <bzbarsky@MIT.EDU>
Date: Fri, 13 May 2011 23:49:11 -0400
Message-ID: <4DCDFBB7.8060708@mit.edu>
http://www.w3.org/TR/html5/rendering.html#punctuation-and-decorations 
says this:

"The wbr element is expected to override the 'white-space' property and 
always provide a line-breaking opportunity."

Why is this desirable?  It seems to contradict what CSS3 Text is trying 
to define in terms of how the various word-wrapping properties interact: 
"text-wrap:none" (which some white-space values set) is really meant to 
be no line breaks except forced ones (and <wbr> is not a forced break at 
all).

Unless there are very strong reasons for this, I would propose that this 
text be removed and <wbr> be considered like any other line-breaking 
opportunity (spaces, &shy;, word separator characters, etc, etc).

In terms of compatibility, WebKit seems to do what the spec says right 
now, while Trident (IE9), Presto (Opera 11), and Gecko (trunk) don't 
break on <wbr> in "white-space: nowrap".  So if there are web compat 
issues, they're more likely to arise with the spec's suggested behavior, 
I would guess.

-Boris
Received on Friday, 13 May 2011 20:49:11 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:59:33 UTC