W3C home > Mailing lists > Public > public-html-diffs@w3.org > February 2009

spec/Overview.html 1.1922 2752 Filling in the rendering section: <font>

From: poot <cvsmail@w3.org>
Date: Wed, 4 Feb 2009 21:01:38 +0900 (JST)
To: public-html-diffs@w3.org
Message-Id: <20090204120138.5EC902BC51@toro.w3.mag.keio.ac.jp>

Filling in the rendering section: <font> and related changes. (whatwg
r2752)

10.3.6 Punctuation and decorations
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1922.html#punctuation-and-decorations
rules for parsing non-negative integers
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1922.html#rules-for-parsing-non-negative-integers
10.3.5 Fonts and colors
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1922.html#fonts-and-colors

http://people.w3.org/mike/diffs/html5/spec/Overview.diff.html
http://dev.w3.org/cvsweb/html5/spec/Overview.html?r1=1.1921&r2=1.1922&f=h
http://html5.org/tools/web-apps-tracker?from=2751&to=2752

===================================================================
RCS file: /sources/public/html5/spec/Overview.html,v
retrieving revision 1.1921
retrieving revision 1.1922
diff -u -d -r1.1921 -r1.1922
--- Overview.html	4 Feb 2009 10:43:55 -0000	1.1921
+++ Overview.html	4 Feb 2009 11:58:15 -0000	1.1922
@@ -1748,6 +1748,11 @@
 
    <li><p>If <var title="">position</var> is past the end of <var title="">input</var>, return an error.</li>
 
+   <li><p>If the next character is a U+002B PLUS SIGN character (+),
+   advance <var title="">position</var> to the next character.</li>
+
+   <li><p>If <var title="">position</var> is past the end of <var title="">input</var>, return an error.</li>
+
    <li><p>If the next character is not one of U+0030 DIGIT ZERO (0)
    .. U+0039 DIGIT NINE (9), then return an error.</li>
 
@@ -46386,14 +46391,122 @@
   the attribute as a <a href=#presentational-hints title="presentational hints">presentational
   hint</a> setting the element's 'border-top-color',
   'border-right-color', 'border-bottom-color', and
-  'border-right-color' properties to the resulting color.</p><hr><p class=XXX>...font...</p><!-- face=>font-family --><!-- pointsize=>font-size as pt if present;
-       otherwise size=>font-size as follows:
-        int <0: as x-small
-        int >7: as xx-large
-        1,2,3,4,5,6: as x-small,small,medium,large,x-large,xx-large; quirks offsets by one?
-        -6 .. -0 +0 .. +6: add to <basefont size> and treat as above?
-        what values should x-small..xx-large have?
-    --><!-- color --><h4 id=punctuation-and-decorations><span class=secno>10.3.6 </span>Punctuation and decorations</h4><pre class=css>@namespace url(http://www.w3.org/1999/xhtml);
+  'border-right-color' properties to the resulting color.</p><hr><p>When a <code>font</code> element has a <code title=attr-font-color>color</code> attribute, its value is
+  expected to be parsed using the <a href=#rules-for-parsing-a-legacy-color-value>rules for parsing a legacy
+  color value</a>, and the user agent is expected to treat the
+  attribute as a <a href=#presentational-hints title="presentational hints">presentational
+  hint</a> setting the element's 'color' property to the resulting
+  color.<p>When a <code>font</code> element has a <code title=attr-font-face>face</code> attribute, the user agent is
+  expected to treat the attribute as a <a href=#presentational-hints title="presentational
+  hints">presentational hint</a> setting the element's
+  'font-family' property to the attribute's value.<p>When a <code>font</code> element has a <code title=attr-font-pointsize>pointsize</code> attribute, the user
+  agent is expected to parse that attribute's value using the
+  <a href=#rules-for-parsing-non-negative-integers>rules for parsing non-negative integers</a>, and if this
+  doesn't generate an error, then the user agent is expected to use
+  the parsed value as a <em>point</em> length for a <a href=#presentational-hints title="presentational hints">presentational hint</a> for the
+  'font-size' property on the element.<p>When a <code>font</code> element has a <code title=attr-font-size>size</code> attribute, the user agent is
+  expected to use the following steps to treat the attribute as a
+  <a href=#presentational-hints title="presentational hints">presentational hint</a>
+  setting the element's 'font-size' property:<ol><li><p>Let <var title="">input</var> be the attribute's
+   value.</li>
+
+   <li><p>Let <var title="">position</var> be a pointer into <var title="">input</var>, initially pointing at the start of the
+   string.</li>
+
+   <li><p><a href=#skip-whitespace>Skip whitespace</a>.</li>
+
+   <li><p>If <var title="">position</var> is past the end of <var title="">input</var>, there is no <a href=#presentational-hints title="presentational
+   hints">presentational hint</a>. Abort these steps.</li>
+
+   <li><p>If the character at <var title="">position</var> is a U+002B
+   PLUS SIGN character (+), then let <var title="">mode</var> be
+   <i>relative-plus</i>, and advance <var title="">position</var> to
+   the next character. Otherwise, if the character at <var title="">position</var> is a U+002D HYPHEN-MINUS character (-),
+   then let <var title="">mode</var> be <i>relative-minus</i>, and
+   advance <var title="">position</var> to the next
+   character. Otherwise, let <var title="">mode</var> be
+   <i>absolute</i>.</li>
+
+   <li><p><a href=#collect-a-sequence-of-characters>Collect a sequence of characters</a> in the range
+   U+0030 DIGIT ZERO (0) to U+0039 DIGIT NINE (9), and let the
+   resulting sequence be <var title="">digits</var>.</li>
+
+   <li><p>If <var title="">digits</var> is the empty string, there is
+   no <a href=#presentational-hints title="presentational hints">presentational
+   hint</a>. Abort these steps.</li>
+
+   <li><p>Interpret <var title="">digits</var> as a base-ten
+   integer. Let <var title="">size</var> be the resulting
+   number.</li>
+
+   <li> 
+
+    <p>If <var title="">mode</var> is not <i>absolute</i>, run these
+    substeps:</p>
+
+    <ol><li><p>Let <var title="">base</var> be 3.</li>
+
+     <li><p>Let <var title="">base element</var> be the the last
+     <code>basefont</code> element in <a href=#tree-order>tree order</a> that is
+     before the <code>font</code> element, if there is one.</li>
+
+     <li><p>If there is a <var title="">base element</var>, and it has
+     a <code title=attr-basefont-size>size</code> attribute, then
+     apply the <a href=#rules-for-parsing-non-negative-integers>rules for parsing non-negative integers</a> to
+     that attribute's value.</li>
+
+     <li><p>If <var title="">base</var> is greater than 7, let it be
+     7.</li>
+
+     <li><p>If <var title="">base</var> is less than 1, let it be
+     1.</li>
+
+     <li><p>If <var title="">mode</var> is <i>relative-plus</i>, then
+     increment <var title="">value</var> by <var title="">base</var>. Otherwise, decrement <var title="">value</var> by <var title="">base</var>.</li>
+
+    </ol></li>
+
+   <li><p>If <var title="">value</var> is greater than 7, let it be
+   7.</li>
+
+   <li><p>If <var title="">value</var> is less than 1, let it be
+   1.</li>
+
+   <li>
+
+    <p>Set 'font-size' to the keyword corresponding to the value of
+    <var title="">value</var> according to the following table:</p>
+
+    <table><thead><tr><th><var title="">value</var>
+       <th>'font-size' keyword
+       <th>Notes
+     <tbody><tr><td>1
+       <td>xx-small
+       <td>
+      <tr><td>2
+       <td>small
+       <td>
+      <tr><td>3
+       <td>medium
+       <td>
+      <tr><td>4
+       <td>large
+       <td>
+      <tr><td>5
+       <td>x-large
+       <td>
+      <tr><td>6
+       <td>xx-large
+       <td>
+      <tr><td>7
+       <td>xxx-large
+       <td><i>see below</i>
+    </table><p>The 'xxx-large' value is a non-CSS value used here to indicate
+    a font size one "step" larger than 'xx-large'.</p>
+
+   </li>
+
+  </ol><h4 id=punctuation-and-decorations><span class=secno>10.3.6 </span>Punctuation and decorations</h4><pre class=css>@namespace url(http://www.w3.org/1999/xhtml);
 
 :link, :visited, ins, u { text-decoration: underline; }
 abbr[title], acronym[title] { text-decoration: dotted underline; }<!-- XXX CSS3 http://dev.w3.org/csswg/css3-text/#text-decoration-style -->
Received on Wednesday, 4 February 2009 12:02:18 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Saturday, 18 December 2010 06:13:58 GMT