W3C home > Mailing lists > Public > www-html@w3.org > February 2000

White Space

From: Scott Violet <zoz32@hotmail.com>
Date: Mon, 28 Feb 2000 16:56:58 PST
Message-ID: <20000229005658.91045.qmail@hotmail.com>
To: www-html@w3.org
I am a little confused as to the correct parsing of white space, and the 
html specification is not very clear on this.
I am specifically interested in something like the following:
  <p><b>blah </b><i> </i><strike> text
The html spec says:

>For all HTML elements except PRE, sequences of white space separate
>"words" (we use the term "word" here to mean "sequences of non-white
>space characters"). When formatting text, user agents
>should identify these words and lay them out according to
>the conventions of the particular written language (script)
>and target medium.

Refering to the above example, b has only one word as does strike, implying 
there should be no separators, and that it can treated as:


But this is obviously wrong, instead it would appear that in the context of 
p there are two words, and should be rendered as either:
  <p><b>blah </b><strike>text
  <p><b>blah</b><strike> text
or even
  <p><b>blah</b><i> </i><strike>text

The question is, which one is write? What rules are there for determining 
what the scope of whitespace are (in the following example I had to look at 
p to determinie the scope for whitespace.

Are there any definitive rules as to how to handle collapsing of 
	-Scott (zoz32@hotmail.com)
Get Your Private, Free Email at http://www.hotmail.com
Received on Monday, 28 February 2000 19:57:30 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:05:53 UTC