[html5] r1371 - /

whatwg at whatwg.org whatwg at whatwg.org
Sat Mar 8 18:20:01 PST 2008


Author: ianh
Date: 2008-03-08 18:20:00 -0800 (Sat, 08 Mar 2008)
New Revision: 1371

Modified:
   index
   source
Log:
[] (0) define formatBlock more generally.

Modified: index
===================================================================
--- index	2008-03-09 01:46:02 UTC (rev 1370)
+++ index	2008-03-09 02:20:00 UTC (rev 1371)
@@ -35862,56 +35862,41 @@
     title=command-formatBlock><code>formatBlock</code></dfn>
 
    <dd>
-    <p><strong>Action:</strong> This command changes the semantics of the
-     blocks containing the selection.</p>
+    <p><strong>Action:</strong> The user agent must run the following steps:</p>
 
-    <p>If there is no selection, then, where in the description below refers
-     to the selection, the user agent must act as if the selection was an
-     empty range at the caret position.</p>
+    <ol>
+     <li>
+      <p>If the <var title="">value</var> argument wasn't specified, abort
+       these steps without doing anything.
 
-    <p>If the <var title="">value</var> parameter is not specified or is not
-     a case-insensitive<!-- XXX ASCII--> match for one of the following
-     strings:</p>
+     <li>
+      <p>If the <var title="">value</var> argument has a leading U+003C
+       LESS-THAN SIGN character ('&lt') and a trailing U+003E GREATER-THAN
+       SIGN character ('>'), then remove the first and last characters from
+       <var title="">value</var>.
 
-    <ul class=brief>
-     <li><code title=""><address></code>
+     <li>
+      <p>If <var title="">value</var> is (now) a case-insensitive<!--
+      XXX ASCII-->
+       match for the tag name of an element defined by this specification
+       that is defined to be a <span>prose element</span> but not a
+       <span>phrasing element</span>, then, for every position in the
+       selection, take the furthest <a href="#flow-content0">flow content</a>
+       ancestor element of that position that contains only <a
+       href="#phrasing0">phrasing content</a>, and, if that element is <a
+       href="#editable0">editable</a>, and has a content model that allows it
+       to contain <span>prose content</span> other than <a
+       href="#phrasing0">phrasing content</a>, and has a parent element whose
+       content model allows that parent to contain any <span>prose
+       content</span>, rename the element (as if the <code
+       title="">Element.renameNode()</code> method had been used) to <var
+       title="">value</var>, using the HTML namespace.</p>
 
-     <li><code title=""><aside></code>
+      <p>If there is no selection, then, where in the description below
+       refers to the selection, the user agent must act as if the selection
+       was an empty range (with just one position) at the caret position.</p>
+    </ol>
 
-     <li><code title=""><div></code>
-
-     <li><code title=""><h1></code>
-
-     <li><code title=""><h2></code>
-
-     <li><code title=""><h3></code>
-
-     <li><code title=""><h4></code>
-
-     <li><code title=""><h5></code>
-
-     <li><code title=""><h6></code>
-
-     <li><code title=""><nav></code>
-
-     <li><code title=""><p></code>
-
-     <li><code title=""><pre></code></li>
-     <!-- XXX this list is incomplete -->
-    </ul>
-
-    <p>...then the user agent must do nothing.</p>
-
-    <p>Otherwise, the user agent must, for every position in the selection,
-     take the furthest <a href="#flow-content0">flow content</a> ancestor
-     element of that position that contains only <a
-     href="#phrasing0">phrasing content</a>, and, if that element is a
-     descendant of the editing host, rename it (as if the <code
-     title="">Element.renameNode()</code> method had been used) according to
-     the <var title="">value</var>, by stripping the leading
-     <code><</code> character and the trailing <code>></code> character
-     and using the rest as the new tag name, using the HTML namespace.</p>
-
    <dd><strong>Enabled When:</strong> The document is <a href="#ready">ready
     for editing host commands</a>.
 

Modified: source
===================================================================
--- source	2008-03-09 01:46:02 UTC (rev 1370)
+++ source	2008-03-09 02:20:00 UTC (rev 1371)
@@ -33261,46 +33261,45 @@
 
    <dd>
 
-    <p><strong>Action:</strong> This command changes the semantics of
-    the blocks containing the selection.</p>
+    <p><strong>Action:</strong> The user agent must run the following
+    steps:</p>
 
-    <p>If there is no selection, then, where in the description below
-    refers to the selection, the user agent must act as if the
-    selection was an empty range at the caret position.</p>
+    <ol>
 
-    <p>If the <var title="">value</var> parameter is not specified or
-    is not a case-insensitive<!-- XXX ASCII--> match for one of the
-    following strings:</p>
+     <li><p>If the <var title="">value</var> argument wasn't
+     specified, abort these steps without doing anything.</p></li>
 
-    <ul class="brief">
-     <li><code title=""><address></code></li>
-     <li><code title=""><aside></code></li>
-     <li><code title=""><div></code></li>
-     <li><code title=""><h1></code></li>
-     <li><code title=""><h2></code></li>
-     <li><code title=""><h3></code></li>
-     <li><code title=""><h4></code></li>
-     <li><code title=""><h5></code></li>
-     <li><code title=""><h6></code></li>
-     <li><code title=""><nav></code></li>
-     <li><code title=""><p></code></li>
-     <li><code title=""><pre></code></li>
-     <!-- XXX this list is incomplete -->
-    </ul>
+     <li><p>If the <var title="">value</var> argument has a leading
+     U+003C LESS-THAN SIGN character ('&lt') and a trailing U+003E
+     GREATER-THAN SIGN character ('>'), then remove the first and last
+     characters from <var title="">value</var>.</p></li>
 
-    <p>...then the user agent must do nothing.</p>
+     <li>
 
-    <p>Otherwise, the user agent must, for every position in the
-    selection, take the furthest <span>flow content</span> ancestor
-    element of that position that contains only <span>phrasing
-    content</span>, and, if that element is a descendant of the
-    editing host, rename it (as if the <code
-    title="">Element.renameNode()</code> method had been used)
-    according to the <var title="">value</var>, by stripping the
-    leading <code><</code> character and the trailing
-    <code>></code> character and using the rest as the new tag
-    name, using the HTML namespace.</p>
+      <p>If <var title="">value</var> is (now) a case-insensitive<!--
+      XXX ASCII--> match for the tag name of an element defined by
+      this specification that is defined to be a <span>prose
+      element</span> but not a <span>phrasing element</span>, then,
+      for every position in the selection, take the furthest
+      <span>flow content</span> ancestor element of that position that
+      contains only <span>phrasing content</span>, and, if that
+      element is <span>editable</span>, and has a content model that
+      allows it to contain <span>prose content</span> other than
+      <span>phrasing content</span>, and has a parent element whose
+      content model allows that parent to contain any <span>prose
+      content</span>, rename the element (as if the <code
+      title="">Element.renameNode()</code> method had been used) to
+      <var title="">value</var>, using the HTML namespace.</p>
 
+      <p>If there is no selection, then, where in the description
+      below refers to the selection, the user agent must act as if the
+      selection was an empty range (with just one position) at the
+      caret position.</p>
+
+     </li>
+
+    </ol>
+
    </dd>
    <dd><strong>Enabled When:</strong> The document is <span>ready for
    editing host commands</span>.</dd>




More information about the Commit-Watchers mailing list