Skip to content

Commit 9415b97

Browse files
committed
[css2] Generated. Do not edit!
--HG-- extra : convert_revision : svn%3A73dc7c4b-06e6-40f3-b4f7-9ed1dbc14bfc/trunk%403034
1 parent bc7236d commit 9415b97

21 files changed

+3436
-2818
lines changed

css2/changes.html

Lines changed: 275 additions & 139 deletions
Large diffs are not rendered by default.

css2/cover.html

Lines changed: 76 additions & 69 deletions
Large diffs are not rendered by default.

css2/diffs-rec/changes.html

Lines changed: 275 additions & 139 deletions
Large diffs are not rendered by default.

css2/diffs-rec/cover.html

Lines changed: 91 additions & 84 deletions
Large diffs are not rendered by default.

css2/diffs-rec/grammar.html

Lines changed: 45 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,11 @@ <H1><a name="q0">Appendix <del>D. The</del><ins>G.</ins> Grammar of <del>CSS2<
2929
<li class="tocline2"><a href="grammar.html#grammar" class="tocxref"> <del>D.1</del><ins>G.1</ins> Grammar</a>
3030
<li class="tocline2"><a href="grammar.html#scanner" class="tocxref"> <del>D.2</del><ins>G.2</ins> Lexical scanner</a>
3131
<li class="tocline2"><a href="grammar.html#tokenizer-diffs" class="tocxref"> <del>D.3</del><ins>G.3</ins> Comparison of tokenization in <del>CSS2</del><ins>CSS&nbsp;2.1</ins> and CSS1</a>
32+
<li class="tocline2"><a href="grammar.html#q4" class="tocxref"> <del>This appendix is normative.</del><ins>G.4 Implementation note</ins></a>
3233
</ul>
3334
</div>
3435

35-
<P> <del>This appendix is normative.</del>The grammar below defines the syntax of <del>CSS2.</del><ins>CSS&nbsp;2.1.</ins> It is in some sense,
36+
<P>The grammar below defines the syntax of <del>CSS2.</del><ins>CSS&nbsp;2.1.</ins> It is in some sense,
3637
however, a superset of <del>CSS2</del><ins>CSS&nbsp;2.1</ins> as this specification imposes additional
3738
semantic constraints not expressed in this grammar. A conforming UA
3839
must also adhere to the <a href="./syndata.html#syntax">
@@ -178,15 +179,21 @@ <h2> <del>D.2</del><ins>G.2</ins> <a name="scanner">Lexical scanner</a></h2>
178179
nmchar <del>[a-z0-9-]|{nonascii}|{escape}</del><ins>[_a-z0-9-]|{nonascii}|{escape}</ins>
179180
string1 <del>\"([\t !#$%&amp;(-~]|\\{nl}|\'|{nonascii}|{escape})*\"</del><ins>\"([^\n\r\f\\"]|\\{nl}|{escape})*\"</ins>
180181
string2 <del>\'([\t !#$%&amp;(-~]|\\{nl}|\"|{nonascii}|{escape})*\'</del><ins>\'([^\n\r\f\\']|\\{nl}|{escape})*\'
181-
invalid1 \"([^\n\r\f\\"]|\\{nl}|{escape})*
182-
invalid2 \'([^\n\r\f\\']|\\{nl}|{escape})*
183-
182+
badstring1 \"([^\n\r\f\\"]|\\{nl}|{escape})*\\?
183+
badstring2 \'([^\n\r\f\\']|\\{nl}|{escape})*\\?
184+
badcomment1 \/\*[^*]*\*+([^/*][^*]*\*+)*
185+
badcomment2 \/\*[^*]*(\*+[^/*][^*]*)*
186+
baduri1 url\({w}([!#$%&*-\[\]-~]|{nonascii}|{escape})*{w}
187+
baduri2 url\({w}{string}{w}
188+
baduri3 url\({w}{badstring}
184189
comment \/\*[^*]*\*+([^/*][^*]*\*+)*\/</ins>
185190
ident <del>{nmstart}{nmchar}*</del><ins>-?{nmstart}{nmchar}*</ins>
186191
name {nmchar}+
187192
num [0-9]+|[0-9]*"."[0-9]+
188193
string {string1}|{string2}
189-
<ins>invalid {invalid1}|{invalid2}</ins>
194+
<ins>badstring {badstring1}|{badstring2}
195+
badcomment {badcomment1}|{badcomment2}
196+
baduri {baduri1}|{baduri2}|{baduri3}</ins>
190197
url ([!#$%&amp;*-~]|{nonascii}|{escape})*
191198
<del>w</del><ins>s</ins> [ <del>\t\r\n\f]*</del><ins>\t\r\n\f]+
192199
w {s}?</ins>
@@ -217,14 +224,15 @@ <h2> <del>D.2</del><ins>G.2</ins> <a name="scanner">Lexical scanner</a></h2>
217224
<del>[ \t\r\n\f]+</del><ins>{s}</ins> {return S;}
218225

219226
<del>\/\*[^*]*\*+([^/][^*]*\*+)*\/</del><ins>\/\*[^*]*\*+([^/*][^*]*\*+)*\/</ins> /* ignore comments */
227+
<ins>{badcomment} /* unclosed comment at EOF */</ins>
220228

221229
"&lt;!--" {return CDO;}
222230
"-->" {return CDC;}
223231
"~=" {return INCLUDES;}
224232
"|=" {return DASHMATCH;}
225233

226234
{string} {return STRING;}
227-
<ins>{invalid} {return INVALID; /* unclosed string */}</ins>
235+
<ins>{badstring} {return BAD_STRING);}</ins>
228236

229237
{ident} {return IDENT;}
230238

@@ -259,6 +267,7 @@ <h2> <del>D.2</del><ins>G.2</ins> <a name="scanner">Lexical scanner</a></h2>
259267

260268
<del>"url("{w}{string}{w}")"</del><ins>{U}{R}{L}"("{w}{string}{w}")"</ins> {return URI;}
261269
<del>"url("{w}{url}{w}")"</del><ins>{U}{R}{L}"("{w}{url}{w}")"</ins> {return URI;}
270+
<ins>{baduri} {return BAD_URI);}</ins>
262271

263272
{ident}"(" {return FUNCTION;}
264273

@@ -310,6 +319,36 @@ <h2> <del>D.3</del><ins>G.3</ins> <a name="tokenizer-diffs">Comparison of tokeni
310319
escaped <del>(".\55ft")</del><ins>(".\35 5ft")</ins>
311320
</ul>
312321

322+
<h2><a name="q4"><ins>G.4 Implementation note</ins></a></h2>
323+
324+
<p><ins>This section is non-normative.</ins>
325+
326+
<p><ins>The lexical scanner for the CSS core syntax in</ins> <a
327+
href="syndata.html#tokenization"><ins>section&nbsp;4.1.1</ins></a> <ins>can be
328+
implemented as a scanner without back-up. In Lex notation, that
329+
requires the addition of the following patterns (which do not change
330+
the returned tokens, only the efficiency of the scanner):</ins>
331+
332+
<pre>
333+
<ins>{ident}/\\ return IDENT;
334+
#{name}/\\ return HASH;
335+
@{ident}/\\ return ATKEYWORD;
336+
#/\\ return DELIM;
337+
@/\\ return DELIM;
338+
@/- return DELIM;
339+
@/-\\ return DELIM;
340+
-/\\ return DELIM;
341+
-/- return DELIM;
342+
\</ins></! return DELIM;
343+
\</!- return DELIM;
344+
{num}{ident}/\\ return DIMENSION;
345+
{num}/\\ return NUMBER;
346+
{num}/- return NUMBER;
347+
{num}/-\\ return NUMBER;
348+
[0-9]+/\. return NUMBER;
349+
u/\+ return IDENT;
350+
u\+[0-9a-f?]{1,6}/- return UNICODE_RANGE;
351+
</pre>
313352

314353
<hr class="navbar">
315354

css2/diffs-rec/selector.html

Lines changed: 18 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -494,13 +494,15 @@ <H3>5.8.2 <a name="default-attrs">Default attribute values in DTDs</a></H3>
494494
attribute selectors.</ins> Style sheets should be designed so that they work
495495
even if the default values are not included in the document tree.
496496

497-
<p> <del>Example(s): For example, consider an element EXAMPLE with an attribute "notation" that has</del><ins>More precisely,</ins> a <del>default value</del><ins>UA is</ins> <em><ins>not</ins></em> <ins>required to read an "external
498-
subset"</ins> of <del>"decimal".</del>the DTD <del>fragment might be &lt;!ATTLIST EXAMPLE notation (decimal,octal) "decimal"> If the style sheet contains the rules EXAMPLE[notation=decimal] {</del><ins>but</ins> <em><ins>is</ins></em> <ins>required to look for default
499-
attribute values in the document's "internal subset." (See</ins> <a href="refs.html#ref-XML10" rel="biblioentry" class="noxref"><span class="normref"><ins>[XML10]</ins></span></a>
500-
<ins>for definitions of these subsets.)</ins>
501-
502-
<p><ins>A UA that recognizes an XML namespace</ins> <a href="refs.html#ref-XMLNAMESPACES" rel="biblioentry" class="noxref"><span class="informref"><ins>[XMLNAMESPACES]</ins></span></a> <ins>is not
503-
required to use its knowledge of that namespace to treat default
497+
<p> <del>Example(s): For example, consider an element EXAMPLE with</del><ins>More precisely, a UA may, but is</ins> <em><ins>not</ins></em> <ins>required to, read</ins> an <ins>"external
498+
subset" of the DTD but</ins> <em><ins>is</ins></em> <ins>required to look for default</ins>
499+
attribute <del>"notation" that has</del><ins>values in the document's "internal subset." (See</ins> <a href="refs.html#ref-XML10" rel="biblioentry" class="noxref"><span class="normref"><ins>[XML10]</ins></span></a>
500+
<ins>for definitions of these subsets.)
501+
Depending on the UA,</ins> a default <ins>attribute</ins> value <del>of</del><ins>defined in the external
502+
subset of the DTD might or might not appear in the document tree.</ins>
503+
504+
<p><ins>A UA that recognizes an XML namespace</ins> <a href="refs.html#ref-XMLNAMESPACES" rel="biblioentry" class="noxref"><span class="informref"><ins>[XMLNAMESPACES]</ins></span></a> <ins>may, but is not
505+
required to, use its knowledge of that namespace to treat default
504506
attribute values as if they were present in the document. (E.g., an
505507
XHTML UA is not required to use its built-in knowledge of the XHTML
506508
DTD.)</ins>
@@ -511,20 +513,20 @@ <H3>5.8.2 <a name="default-attrs">Default attribute values in DTDs</a></H3>
511513
<div class="example"><P style="display:none"><ins>Example(s):</ins></P>
512514
<P style="display:none"><ins>Example:</ins></P>
513515
<P><ins>For example, consider an element EXAMPLE with an attribute "notation"
514-
that has a default value of "decimal". The DTD fragment might be</ins>
516+
that has a default value of</ins> "decimal". The DTD fragment might be
515517

516518
<pre class="dtd-example">
517-
<ins>&lt;!ATTLIST EXAMPLE notation (decimal,octal) "decimal"></ins>
519+
&lt;!ATTLIST EXAMPLE notation (decimal,octal) "decimal">
518520
</pre>
519521

520-
<p><ins>If the style sheet contains the rules</ins>
522+
<p>If the style sheet contains the rules
521523

522524
<pre class="example">
523-
<ins>EXAMPLE[notation=decimal] {</ins> /*... default property settings ...*/ }
525+
EXAMPLE[notation=decimal] { /*... default property settings ...*/ }
524526
EXAMPLE[notation=octal] { /*... other settings...*/ }
525527
</pre>
526528

527-
<p> <del>then to catch</del>the <del>cases where this</del><ins>first rule will not match elements whose "notation"</ins> attribute
529+
<p> <del>then to catch</del>the <del>cases where this</del><ins>first rule might not match elements whose "notation"</ins> attribute
528530
is set by default, <del>and</del><ins>i.e.,</ins> not <del>explicitly,</del><ins>set explicitly. To catch all cases,</ins> the
529531
<del>following rule might</del><ins>attribute selector for the default value must</ins> be <del>added:</del><ins>dropped:</ins></p>
530532

@@ -620,8 +622,8 @@ <h3>5.8.3 <a name="class-html">Class selectors</a></h3>
620622
not.</em>
621623
</div>
622624

623-
<div class="note"><p><em><strong> <del>5.9 ID selectors Document languages</del><ins>Note:</ins></strong> <ins>If an element has
624-
multiple class attributes, their values must be concatenated with
625+
<div class="note"><p><em><strong> <del>5.9 ID selectors Document languages may contain attributes that are declared to</del><ins>Note:</ins></strong> <ins>If an element has
626+
multiple class attributes, their values must</ins> be <del>of type</del><ins>concatenated with
625627
spaces between the values before searching for the class. As of this
626628
time the working group is not aware of any manner in which this
627629
situation can be reached, however, so this behavior is explicitly
@@ -630,8 +632,8 @@ <h3>5.8.3 <a name="class-html">Class selectors</a></h3>
630632

631633
<h2><ins>5.9</ins> <a name="id-selectors"><ins>ID selectors</ins></a></h2>
632634

633-
<P><ins>Document languages</ins> may contain attributes that are declared to be
634-
of type ID. What makes attributes of type ID special is that no two
635+
<P><ins>Document languages may contain attributes that are declared to be
636+
of type</ins> ID. What makes attributes of type ID special is that no two
635637
such attributes can have the same value; whatever the document
636638
language, an ID attribute can be used to uniquely identify its
637639
element. In HTML all ID attributes are named "id"; XML

0 commit comments

Comments
 (0)