W3C home > Mailing lists > Public > html-tidy@w3.org > January to March 2007

Re: Preventing Tidy from eating spaces

From: Elliotte Harold <elharo@metalab.unc.edu>
Date: Sun, 04 Feb 2007 06:49:30 -0500
Message-ID: <45C5C84A.10700@metalab.unc.edu>
To: Bjoern Hoehrmann <derhoermi@gmx.net>
CC: Trevor Harmon <trevor@vocaro.com>, html-tidy@w3.org

Bjoern Hoehrmann wrote:

> Tidy does have limited XML support, see the -xml option and --input-xml
> configuration options. And yes, the same applies to HTML documents; most
> browsers treat most white space in HTML documents as significant while
> Tidy considers most of it insignificant and so it is easy to construct
> documents that break after tidying. It just so happens Tidy makes much
> better assumptions in HTML mode than in XML mode.

Really. Could you elaborate? Outside of pre elements and a couple of 
others no one ever uses any more, I don't think most browsers treat 
white space as all that significant. Maybe in the DOM, but not in the 
rendering. Certainly the difference between one space and no space 
matters, but not the difference between a space and a line break or a 
space and ten spaces.

´╗┐Elliotte Rusty Harold  elharo@metalab.unc.edu
Java I/O 2nd Edition Just Published!
Received on Sunday, 4 February 2007 11:49:43 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:38:56 UTC