- From: Felix Sasaki <fsasaki@w3.org>
- Date: Thu, 2 Aug 2012 08:24:55 +0200
- To: Yves Savourel <ysavourel@enlaso.com>
- Cc: Shaun McCance <shaunm@gnome.org>, public-multilingualweb-lt@w3.org
- Message-ID: <CAL58czqV4jt-vTLhweZCimZOy_RWOsAdokdBLt7fiBLZyhxgBg@mail.gmail.com>
Very good point, Yves - the mention of HTML. Actually, it seems we cannot apply this data category to HTML5. See http://www.w3.org/TR/2012/WD-html-polyglot-20120329/#disallowed-attributes If I am reading this correct. So we probably should say "this data category is not applicable for HTML5 documents". Felix 2012/8/2 Yves Savourel <ysavourel@enlaso.com> > Hi Shaun, > > One typo: xml:space="preserve" should probably not be in the example for > global. > > (minor) Possible text tweak: In the text with the examples we use > "whitespace... ...must be treated literally". I see what you mean, but it > may be more clear to just say "whitespace characters... ...must be > preserved." > > One note: we never say anywhere what are the whitespace characters. Don't > XML and HTML have different views on this? > > Cheers, > -ys > > > -----Original Message----- > From: Shaun McCance [mailto:shaunm@gnome.org] > Sent: Thursday, August 02, 2012 1:37 AM > To: public-multilingualweb-lt@w3.org > Subject: [ACTION 177] Preserve Space > > I posted a call for consensus about Preserve Space a couple week ago. This > is a more fleshed out text for the spec, with examples. > > I didn't get feedback on the data category itself, but I think it's > non-controversial. If nobody objects, I'll add this text to the draft after > a few days. > > ================ > > = Definition > > The Preserve Space data category indicates how whitespace should be > handled in content. The possible values for the Preserve Space data > category are "default" and "preserve" and carry the same meaning as the > corresponding values of the xml:space attribute. The default value is > "default". > > = Implementation > > The Preserve Space data category can be expressed with global rules, or > locally using the xml:space attribute. > > GLOBAL: The preserveSpaceRule element contains the following: > > * A required selector attribute. It contains an XPath expression which > selects the nodes to which this rule applies. > > * A required space attribute with the value "default" or "preserve". > > Example ##: The Preserve Space data category expressed globally > > The preserveSpaceRule element specifies that whitespace in all > verse elements must be treated literally. > > <book> > <info> > <its:rules xmlns:its="http://www.w3.org/2005/11/its" > its:version="2.0"> > <its:preserveSpaceRule selector="//verse" space="preserve"/> > </its:rules> > </info> > <verse xml:space="preserve"> > 'Twas brillig, and the slithy toves > Did gyre and gimble in the wabe; > All mimsy were the borogoves, > And the mome raths outgrabe. > </verse> > </book> > > LOCAL: The xml:space attribute, as defined in section 2.10 of [XML 1.0], > maps exactly to the Preserve Space data category. > > Example ##: The Preserve Space data category expressed locally > > The standard xml:space attribute specifies that the whitespace > in the verse element must be treated literally. > > <book > xmlns:its="http://www.w3.org/2005/11/its" > its:version="2.0"> > <verse xml:space="preserve"> > 'Twas brillig, and the slithy toves > Did gyre and gimble in the wabe; > All mimsy were the borogoves, > And the mome raths outgrabe. > </verse> > </book> > > > > > > > -- Felix Sasaki DFKI / W3C Fellow
Received on Thursday, 2 August 2012 06:25:22 UTC