W3C home > Mailing lists > Public > www-html@w3.org > July 2001

Re: White space and inline elements

From: William F. Hammond <hammond@csc.albany.edu>
Date: Wed, 25 Jul 2001 13:51:52 -0400 (EDT)
Message-Id: <200107251751.f6PHpq824546@pluto.math.albany.edu>
To: www-html@w3.org
Masayasu Ishikawa <mimasa@w3.org> writes:

> "William F. Hammond" <hammond@csc.albany.edu> wrote:

[ . . . ]

> > My suggestion is that content providers should be told that writing
> > leading or trailing white space is deprecated inside these inline
> > elements.

Hmmm...  On second thought should "kbd" be allowed to have xml:space
set?  (Now it is not.)  Otherwise, content providers can use "&nbsp;",
I guess; but it's a presentation-centric co-opting.

> That's why the HTML 4 specification, "9.1 White space" says as follows:
>     In order to avoid problems with SGML line break rules and
>     inconsistencies among extant implementations, authors should not rely
>     on user agents to render white space immediately after a start tag or
>     immediately before an end tag. Thus, authors, and in particular
>     authoring tools, should write:

My suggestion should have referenced section 3.2(9) of the XHTML
1.0 spec (26 Jan 2000) found at http://www.w3.org/TR/xhtml1/ .

Please note that, in effect, a processor writing xhtml acquires the
role of "content provider".

Perhaps for additional clarity it should be stated that the presence
or absence of white space before or after such inline elements is
significant.  Perhaps also for clarity the special circumstances
(involving xml:space) for "pre", "script", and "style" should be
spelled out.

[Aside: Why is "script", which cannot have even remotely common effect
across all user agents, tolerated in strict html?  I wonder if the
commercial outfits whose content providers are so fond of it these
days understand the market narrowing consequences of its use?]

                                    -- Bill
Received on Wednesday, 25 July 2001 13:51:58 UTC

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