- From: poot <cvsmail@w3.org>
- Date: Fri, 11 Sep 2009 13:31:25 +0900 (JST)
- To: public-html-diffs@w3.org
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"><p>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.</p>
+<p><i>Maybe it won't be that bad</i>, he told himself. The lie was
+comforting enough to get him through the rest of the night's
+shift.</p>
+<strong><hr></strong>
+<p>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.</p></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 @@
</legend>
</figure></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><pre><code class="lang-c"><span class="keyword">for</span> (<span class="ident">j</span> = 0; <span class="ident">j</span> &lt; 256; <span class="ident">j</span>++) {
+ <span class="ident">i_t3</span> = (<span class="ident">i_t3</span> & 0x1ffff) | (<span class="ident">j</span> &lt;&lt; 17);
+ <span class="ident">i_t6</span> = (((((((<span class="ident">i_t3</span> >> 3) ^ <span class="ident">i_t3</span>) >> 1) ^ <span class="ident">i_t3</span>) >> 8) ^ <span class="ident">i_t3</span>) >> 5) & 0xff;
+ <span class="keyword">if</span> (<span class="ident">i_t6</span> == <span class="ident">i_t1</span>)
+ <span class="keyword">break</span>;
+}</code></pre></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