hixie: <hr> and <span> examples. (whatwg r3804)

hixie: <hr> and <span> examples. (whatwg r3804)

http://dev.w3.org/cvsweb/html5/spec/Overview.html?r1=1.2972&r2=1.2973&f=h
http://html5.org/tools/web-apps-tracker?from=3803&to=3804

===================================================================
RCS file: /sources/public/html5/spec/Overview.html,v
retrieving revision 1.2972
retrieving revision 1.2973
diff -u -d -r1.2972 -r1.2973
--- Overview.html 11 Sep 2009 03:37:59 -0000 1.2972
+++ Overview.html 11 Sep 2009 04:31:01 -0000 1.2973
@@ -12399,7 +12399,37 @@
   </dl><p>The <code><a href="#the-hr-element">hr</a></code> element <a href="#represents">represents</a> a
   <a href="#paragraph">paragraph</a>-level thematic break, e.g. a scene change in
   a story, or a transition to another topic within a section of a
-  reference book.<h4 id="the-br-element"><span class="secno">4.5.3 </span>The <dfn><code>br</code></dfn> element</h4><p class="XXX annotation"><b>Status: </b><i>Implemented and widely deployed</i><dl class="element"><dt>Categories</dt>
+  reference book.<div class="example">
+
+   <p>The following extract from <cite>Pandora's Star</cite> by Peter
+   F. Hamilton shows two paragraphs that precede a scene change and
+   the paragraph that follows it. The scene change, represented in the
+   printed book by a gap containing a solitary centered star between
+   the second and third paragraphs, is here represented using the
+   <code><a href="#the-hr-element">hr</a></code> element.</p>
+
+   <!-- ISBN 1-4050-0020-1; bottom of page 14 -->
+
+   <pre lang="en-GB">&lt;p&gt;Dudley was ninety-two, in his second life, and fast approaching
+time for another rejuvenation. Despite his body having the physical
+age of a standard fifty-year-old, the prospect of a long degrading
+campaign within academia was one he regarded with dread. For a
+supposedly advanced civilization, the Intersolar Commonwearth could be
+appallingly backward at times, not to mention cruel.&lt;/p&gt;
+&lt;p&gt;&lt;i&gt;Maybe it won't be that bad&lt;/i&gt;, he told himself. The lie was
+comforting enough to get him through the rest of the night's
+shift.&lt;/p&gt;
+<strong>&lt;hr&gt;</strong>
+&lt;p&gt;The Carlton AllLander drove Dudley home just after dawn. Like the
+astronomer, the vehicle was old and worn, but perfectly capable of
+doing its job. It had a cheap diesel engine, common enough on a
+semi-frontier world like Gralmond, although its drive array was a
+thoroughly modern photoneural processor. With its high suspension and
+deep-tread tyres it could plough along the dirt track to the
+observatory in all weather and seasons, including the metre-deep snow
+of Gralmond's winters.&lt;/p&gt;</pre>
+
+  </div><h4 id="the-br-element"><span class="secno">4.5.3 </span>The <dfn><code>br</code></dfn> element</h4><p class="XXX annotation"><b>Status: </b><i>Implemented and widely deployed</i><dl class="element"><dt>Categories</dt>
    <dd><a href="#flow-content">Flow content</a>.</dd>
    <dd><a href="#phrasing-content">Phrasing content</a>.</dd>
    <dt>Contexts in which this element may be used:</dt>
@@ -14057,7 +14087,6 @@
  &lt;/legend&gt;
 &lt;/figure&gt;</pre>
 
-
   </div><h4 id="the-samp-element"><span class="secno">4.6.12 </span>The <dfn><code>samp</code></dfn> element</h4><p class="XXX annotation"><b>Status: </b><i>Implemented and widely deployed</i><dl class="element"><dt>Categories</dt>
    <dd><a href="#flow-content">Flow content</a>.</dd>
    <dd><a href="#phrasing-content">Phrasing content</a>.</dd>
@@ -15149,7 +15178,22 @@
   </dl><p>The <code><a href="#the-span-element">span</a></code> element doesn't mean anything on its own,
   but can be useful when used together with other attributes,
   e.g. <code title="attr-class"><a href="#classes">class</a></code>, <code title="attr-lang"><a href="#attr-lang">lang</a></code>, or <code title="attr-dir"><a href="#the-dir-attribute">dir</a></code>. It <a href="#represents">represents</a> its
-  children.<h4 id="usage-summary"><span class="secno">4.6.25 </span>Usage summary</h4><p><i>This section is non-normative.</i><table><thead><tr><th>Element
+  children.<div class="example">
+
+   <p>In this example, a code fragment is marked up using
+   <code><a href="#the-span-element">span</a></code> elements and <code title="attr-class"><a href="#classes">class</a></code> attributes so that its keywords and
+   identifiers can be color-coded from CSS:</p>
+
+   <!-- extract from http://www.cs.cmu.edu/~dst/DeCSS/Gallery/vlc-dvd_css-c.txt -->
+
+   <pre>&lt;pre&gt;&lt;code class="lang-c"&gt;&lt;span class="keyword"&gt;for&lt;/span&gt; (&lt;span class="ident"&gt;j&lt;/span&gt; = 0; &lt;span class="ident"&gt;j&lt;/span&gt; &amp;lt; 256; &lt;span class="ident"&gt;j&lt;/span&gt;++) {
+  &lt;span class="ident"&gt;i_t3&lt;/span&gt; = (&lt;span class="ident"&gt;i_t3&lt;/span&gt; &amp; 0x1ffff) | (&lt;span class="ident"&gt;j&lt;/span&gt; &amp;lt;&amp;lt; 17);
+  &lt;span class="ident"&gt;i_t6&lt;/span&gt; = (((((((&lt;span class="ident"&gt;i_t3&lt;/span&gt; &gt;&gt; 3) ^ &lt;span class="ident"&gt;i_t3&lt;/span&gt;) &gt;&gt; 1) ^ &lt;span class="ident"&gt;i_t3&lt;/span&gt;) &gt;&gt; 8) ^ &lt;span class="ident"&gt;i_t3&lt;/span&gt;) &gt;&gt; 5) &amp; 0xff;
+  &lt;span class="keyword"&gt;if&lt;/span&gt; (&lt;span class="ident"&gt;i_t6&lt;/span&gt; == &lt;span class="ident"&gt;i_t1&lt;/span&gt;)
+    &lt;span class="keyword"&gt;break&lt;/span&gt;;
+}&lt;/code&gt;&lt;/pre&gt;</pre>
+
+  </div><h4 id="usage-summary"><span class="secno">4.6.25 </span>Usage summary</h4><p><i>This section is non-normative.</i><table><thead><tr><th>Element
      <th>Purpose
      <th>Example
    <tbody><tr><td><code><a href="#the-a-element">a</a></code>

Received on Friday, 11 September 2009 04:32:02 UTC