[css3-values] Viewport-percentage lengths are only based on the first page.

Sun, 24 Feb 2013 01:52:32 +0100

author
Simon Sapin <simon.sapin@exyr.org>
date
Sun, 24 Feb 2013 01:52:32 +0100
changeset 7559
1190b94caf9e
parent 7558
33f961bea4f4
child 7560
ee2ff2976a1a

[css3-values] Viewport-percentage lengths are only based on the first page.

Working Group resolution:
http://lists.w3.org/Archives/Public/www-style/2012Nov/0489.html

css3-values/Overview.html file | annotate | diff | comparison | revisions
css3-values/Overview.src.html file | annotate | diff | comparison | revisions
     1.1 --- a/css3-values/Overview.html	Sun Feb 24 01:31:32 2013 +0100
     1.2 +++ b/css3-values/Overview.html	Sun Feb 24 01:52:32 2013 +0100
     1.3 @@ -11,7 +11,7 @@
     1.4     rel=dcterms.rights>
     1.5    <meta content="CSS Values and Units Module Level 3" name=dcterms.title>
     1.6    <meta content=text name=dcterms.type>
     1.7 -  <meta content=2013-02-15 name=dcterms.issued>
     1.8 +  <meta content=2013-02-24 name=dcterms.issued>
     1.9    <meta content="http://dev.w3.org/csswg/css3-values/" name=dcterms.creator>
    1.10    <meta content=W3C name=dcterms.publisher>
    1.11    <meta content="http://dev.w3.org/csswg/css3-values/"
    1.12 @@ -39,7 +39,7 @@
    1.13  
    1.14     <h1>CSS Values and Units Module Level 3</h1>
    1.15  
    1.16 -   <h2 class="no-num no-toc" id=longstatus-date>Editor's Draft 15 February
    1.17 +   <h2 class="no-num no-toc" id=longstatus-date>Editor's Draft 24 February
    1.18      2013</h2>
    1.19  
    1.20     <dl>
    1.21 @@ -1034,9 +1034,10 @@
    1.22      class=css>vh</code></a>’.
    1.23    </dl>
    1.24  
    1.25 -  <p class=note>Note that Paged Media defines how the initial containing
    1.26 -   block transforms across varying page widths. This also affects these
    1.27 -   units.
    1.28 +  <p class=note>Note that Paged Media <a href="#CSS3PAGE"
    1.29 +   rel=biblioentry>[CSS3PAGE]<!--{{CSS3PAGE}}--></a> defines how the initial
    1.30 +   containing block is only based on the first page, even if subsequent pages
    1.31 +   have a different size.
    1.32  
    1.33    <h3 id=absolute-lengths><span class=secno>5.2. </span> Absolute lengths:
    1.34     the ‘<code class=css>cm</code>’, ‘<code class=css>mm</code>’,
    1.35 @@ -1132,7 +1133,7 @@
    1.36  
    1.37    <div class=figure>
    1.38     <p><img
    1.39 -    alt="This diagram illustrates how the definition of a pixel 		             depends on the users distance from the viewing surface 		             (paper or screen). 		             The image depicts the user looking at two planes, one 		             28 inches (71 cm) from the user, the second 140 inches 		             (3.5 m) from the user. An expanding cone is projected 		             from the user's eye onto each plane. Where the cone 		             strikes the first plane, the projected pixel is 0.26 mm  		             high. Where the cone strikes the second plane, the 		             projected pixel is 1.4 mm high."
    1.40 +    alt="This diagram illustrates how the definition of a pixel 		             depends on the users distance from the viewing surface 		             (paper or screen). 		             The image depicts the user looking at two planes, one 		             28 inches (71 cm) from the user, the second 140 inches 		             (3.5 m) from the user. An expanding cone is projected 		             from the user's eye onto each plane. Where the cone 		             strikes the first plane, the projected pixel is 0.26 mm 		             high. Where the cone strikes the second plane, the 		             projected pixel is 1.4 mm high."
    1.41      src=pixel1.png>
    1.42  
    1.43     <p class=caption>Showing that pixels must become larger if the viewing
    1.44 @@ -1422,9 +1423,9 @@
    1.45  
    1.46     <pre>
    1.47  .foo {
    1.48 -	background-image: linear-gradient(to right, silver, 
    1.49 -	                                            white 50px, 
    1.50 -	                                            white calc(100% - 50px), 
    1.51 +	background-image: linear-gradient(to right, silver,
    1.52 +	                                            white 50px,
    1.53 +	                                            white calc(100% - 50px),
    1.54  	                                            silver);
    1.55  }
    1.56  </pre>
    1.57 @@ -1562,7 +1563,7 @@
    1.58     class=css>calc()</code></a>’ expression can be represented as either a
    1.59     number or a tuple of a dimension and a percentage.
    1.60     <!-- http://lists.w3.org/Archives/Public/www-style/2010May/0001.html
    1.61 -	This has notes on how we should handle things when calc() is extended to 
    1.62 +	This has notes on how we should handle things when calc() is extended to
    1.63  	handle unit mult/div. Related to this is <unit>mod<unit>, which can return
    1.64  	0 and thus introduce computed-time division-by-zero. -->
    1.65  
    1.66 @@ -1945,11 +1946,11 @@
    1.67     <pre>
    1.68  content: attr(title color); /* 'content' doesn't accept colors */
    1.69  
    1.70 -content: attr(end-of-quote string, inherit) close-quote; 
    1.71 +content: attr(end-of-quote string, inherit) close-quote;
    1.72  /* the 'inherit' value is not allowed there, since the result would be
    1.73  'inherit close-quote', which is invalid. */
    1.74  
    1.75 -margin: attr(vertical length) attr(horizontal deg); 
    1.76 +margin: attr(vertical length) attr(horizontal deg);
    1.77  /* deg units are not valid at that point */
    1.78  
    1.79  color: attr(color); /* 'color' doesn't accept strings */</pre>
    1.80 @@ -2355,6 +2356,16 @@
    1.81     </dd>
    1.82     <!---->
    1.83  
    1.84 +   <dt id=CSS3PAGE>[CSS3PAGE]
    1.85 +
    1.86 +   <dd>Håkon Wium Lie; Melinda Grant. <a
    1.87 +    href="http://www.w3.org/TR/2006/WD-css3-page-20061010"><cite>CSS3 Module:
    1.88 +    Paged Media.</cite></a> 10 October 2006. W3C Working Draft. (Work in
    1.89 +    progress.) URL: <a
    1.90 +    href="http://www.w3.org/TR/2006/WD-css3-page-20061010">http://www.w3.org/TR/2006/WD-css3-page-20061010</a>
    1.91 +   </dd>
    1.92 +   <!---->
    1.93 +
    1.94     <dt id=MEDIAQ>[MEDIAQ]
    1.95  
    1.96     <dd>Florian Rivoal. <a
     2.1 --- a/css3-values/Overview.src.html	Sun Feb 24 01:31:32 2013 +0100
     2.2 +++ b/css3-values/Overview.src.html	Sun Feb 24 01:52:32 2013 +0100
     2.3 @@ -175,9 +175,9 @@
     2.4  			all of which must occur, in any order.
     2.5  		<li>A double bar (||) separates two or more options:
     2.6  			one or more of them must occur, in any order.
     2.7 -		<li>A bar (|) separates two or more alternatives: 
     2.8 +		<li>A bar (|) separates two or more alternatives:
     2.9  			exactly one of them must occur.
    2.10 -		<li>Brackets ([&nbsp;]) are for grouping. 
    2.11 +		<li>Brackets ([&nbsp;]) are for grouping.
    2.12  	</ul>
    2.13  
    2.14  	<p>Juxtaposition is stronger than the double ampersand, the double
    2.15 @@ -311,7 +311,7 @@
    2.16  		<p>For example, here is the value definition for the 'border-collapse'
    2.17  		property:</p>
    2.18  		<pre>Value:&nbsp;collapse | separate</pre>
    2.19 -		
    2.20 +
    2.21  		<p>And here is an example of its use:</p>
    2.22  		<pre>table { border-collapse: separate }</pre>
    2.23  	</div>
    2.24 @@ -399,7 +399,7 @@
    2.25  	so that the resulting value is a valid <code>URL</code> token,
    2.26  	e.g. ''url(open\(parens)'', ''url(close\)parens)''.
    2.27  	Depending on the type of URL, it might also be possible to write these
    2.28 -	characters as URI-escapes (e.g. ''url(open%28parens)'' or 
    2.29 +	characters as URI-escapes (e.g. ''url(open%28parens)'' or
    2.30  	''url(close%29parens)'') as described in [[URI]].
    2.31  	Alternatively a URL containing such characters may be represented as
    2.32  	a quoted <a href="#strings">string</a> within the ''url()'' notation.
    2.33 @@ -412,7 +412,7 @@
    2.34  	of the style sheet, not that of the source document.
    2.35  
    2.36  	<p>When a <i>&lt;url></i> appears in the computed value of a property,
    2.37 -	it is resolved to an absolute URL, as described in the preceding 
    2.38 +	it is resolved to an absolute URL, as described in the preceding
    2.39  	paragraph.
    2.40  	The computed value of a URI that the UA cannot resolve to an absolute
    2.41  	URI is the specified value.</p>
    2.42 @@ -460,7 +460,7 @@
    2.43  
    2.44  <h3 id="numbers">
    2.45  Numbers: the ''&lt;number>'' type</h3>
    2.46 -	
    2.47 +
    2.48  	<p>Number values are denoted by
    2.49  	<dfn id="number-value"><var>&lt;number></var></dfn>.
    2.50  	A <dfn>number</dfn> is either an &lt;integer> or
    2.51 @@ -474,7 +474,7 @@
    2.52  Percentages: the ''&lt;percentage>'' type</h3>
    2.53  
    2.54  	<p>A <dfn>percentage</dfn> value is denoted by
    2.55 -	<dfn id="percentage-value"><var>&lt;percentage></var></dfn>, 
    2.56 +	<dfn id="percentage-value"><var>&lt;percentage></var></dfn>,
    2.57  	consists of a <i>&lt;number></i> immediately followed by a percent
    2.58  	sign ''%''. It corresponds to the <code>PERCENTAGE</code> token in the
    2.59  	<a href="http://www.w3.org/TR/CSS21/syndata.html#tokenization">grammar</a>.
    2.60 @@ -494,9 +494,9 @@
    2.61  
    2.62  	<p>Lengths refer to distance measurements and are denoted by
    2.63  	<dfn id="length-value"><var>&lt;length></var></dfn> in the
    2.64 -	property definitions. 
    2.65 +	property definitions.
    2.66  	A length is a <i>dimension</i>.
    2.67 -	However, for zero lengths the unit identifier is optional 
    2.68 +	However, for zero lengths the unit identifier is optional
    2.69  	(i.e. can be syntactically represented as the <var>&lt;number></var> ''0'').
    2.70  
    2.71  	<p>A <dfn>dimension</dfn> is a <i>number</i> immediately followed by a
    2.72 @@ -528,7 +528,7 @@
    2.73  	units can more easily scale from one output environment to another.
    2.74  
    2.75  	<p>The relative units are:</p>
    2.76 -	
    2.77 +
    2.78  	<table class="data">
    2.79  	<caption>Informative Summary of Relative Units</caption>
    2.80  	<thead>
    2.81 @@ -563,8 +563,8 @@
    2.82  	<p>Aside from ''rem'' (which refers to the font-size of the root element),
    2.83  	the font-relative lengths refer to the computed font metrics of the
    2.84  	element on which they are used.
    2.85 -	The exception is when they occur in the value of the 'font-size' property 
    2.86 -	itself, in which case they refer to the computed font metrics of the parent element 
    2.87 +	The exception is when they occur in the value of the 'font-size' property
    2.88 +	itself, in which case they refer to the computed font metrics of the parent element
    2.89  	(or the computed font metrics corresponding to the initial values of the 'font'
    2.90  	property, if the element has no parent).
    2.91  
    2.92 @@ -635,8 +635,9 @@
    2.93  		<dd>Equal to the larger of ''vw'' or ''vh''.
    2.94  	</dl>
    2.95  
    2.96 -	<p class='note'>Note that Paged Media defines how the initial containing block
    2.97 -	transforms across varying page widths.  This also affects these units.</p>
    2.98 +	<p class='note'>Note that Paged Media [[CSS3PAGE]] defines how
    2.99 +	the initial containing block is only based on the first page,
   2.100 +	even if subsequent pages have a different size.</p>
   2.101  
   2.102  <h3 id="absolute-lengths">
   2.103  Absolute lengths: the ''cm'', ''mm'', ''in'', ''pt'', ''pc'', ''px'' units</h3>
   2.104 @@ -686,12 +687,12 @@
   2.105  	it is recommended instead that the anchor unit be the pixel unit. For
   2.106  	such devices it is recommended that the pixel unit refer to the whole
   2.107  	number of device pixels that best approximates the reference pixel.
   2.108 -	
   2.109 +
   2.110  	<p class="note">Note that if the anchor unit is the pixel unit,
   2.111  	the physical units might not match their physical measurements.
   2.112  	Alternatively if the anchor unit is a physical unit, the pixel
   2.113  	unit might not map to a whole number of device pixels.</p>
   2.114 -	
   2.115 +
   2.116  	<p class="note">Note that this definition of the pixel unit and
   2.117  	the physical units differs from previous versions of CSS. In
   2.118  	particular, in previous versions of CSS the pixel unit and the
   2.119 @@ -708,7 +709,7 @@
   2.120  	length of 28 inches, the visual angle is therefore about 0.0213
   2.121  	degrees. For reading at arm's length, 1px thus corresponds to about
   2.122  	0.26&nbsp;mm (1/96&nbsp;inch).
   2.123 -	
   2.124 +
   2.125  	<p>The image below illustrates the effect of viewing distance on
   2.126  	the size of a reference pixel: a reading distance of 71&nbsp;cm
   2.127  	(28&nbsp;inches) results in a reference pixel of 0.26&nbsp;mm,
   2.128 @@ -724,7 +725,7 @@
   2.129  		             28 inches (71 cm) from the user, the second 140 inches
   2.130  		             (3.5 m) from the user. An expanding cone is projected
   2.131  		             from the user's eye onto each plane. Where the cone
   2.132 -		             strikes the first plane, the projected pixel is 0.26 mm 
   2.133 +		             strikes the first plane, the projected pixel is 0.26 mm
   2.134  		             high. Where the cone strikes the second plane, the
   2.135  		             projected pixel is 1.4 mm high.">
   2.136  		<p class="caption">Showing that pixels must become larger if the
   2.137 @@ -764,7 +765,7 @@
   2.138  		<dt><dfn title="deg">deg</dfn>
   2.139  		<dd>Degrees. There are 360 degrees in a full circle.
   2.140  		<dt><dfn title="grad">grad</dfn>
   2.141 -		<dd>Gradians, also known as "gons" or "grades". There are 400 gradians 
   2.142 +		<dd>Gradians, also known as "gons" or "grades". There are 400 gradians
   2.143  		in a full circle.
   2.144  		<dt><dfn title="rad">rad</dfn>
   2.145  		<dd>Radians. There are 2&pi; radians in a full circle.
   2.146 @@ -795,7 +796,7 @@
   2.147  
   2.148  <h3 id="frequency">
   2.149  Frequencies: the ''&lt;frequency>'' type and ''Hz'', ''kHz'' units</h3>
   2.150 -	
   2.151 +
   2.152  	<p>Frequency values are <i>dimensions</i> denoted by
   2.153  	<dfn id="frequency-value">&lt;frequency></dfn>.
   2.154  	The frequency unit identifiers are:</p>
   2.155 @@ -806,7 +807,7 @@
   2.156  	  <dt><dfn title="kHz">kHz</dfn>
   2.157  	  <dd>KiloHertz. A kiloHertz is 1000 Hertz.
   2.158  	</dl>
   2.159 -	
   2.160 +
   2.161  	<p>For example, when representing sound pitches, 200Hz (or 200hz)
   2.162  	is a bass sound, and 6kHz (or 6khz) is a treble sound.</p>
   2.163  
   2.164 @@ -822,13 +823,13 @@
   2.165  		<dt><dfn>dpcm</dfn></dt>
   2.166  		<dd>dots per centimeter</dd>
   2.167  
   2.168 -		<dt><dfn>dppx</dfn></dt> 
   2.169 +		<dt><dfn>dppx</dfn></dt>
   2.170  		<dd>dots per ''px'' unit</dd>
   2.171  	</dl>
   2.172  
   2.173  	<p>The <var>&lt;resolution></var> unit represents the size of a single "dot" in a
   2.174  	graphical representation by indicating how many of these dots fit in a
   2.175 -	CSS 'in', 'cm', or 'px'. 
   2.176 +	CSS 'in', 'cm', or 'px'.
   2.177  	For uses, see e.g. the  ''resolution'' media query in [[MEDIAQ]]
   2.178  	or the 'image-resolution' property defined in [[CSS3-IMAGES]].
   2.179  
   2.180 @@ -883,15 +884,15 @@
   2.181  
   2.182  	<p>
   2.183  		A <dfn>functional notation</dfn> is a type of component value
   2.184 -		that can represent more complex types or invoke special processing. 
   2.185 -		The syntax starts with the name of the function 
   2.186 +		that can represent more complex types or invoke special processing.
   2.187 +		The syntax starts with the name of the function
   2.188  		immediately followed by a left parenthesis
   2.189  		(i.e. a <code>FUNCTION</code> token)
   2.190 -		followed by the argument(s) to the notation 
   2.191 +		followed by the argument(s) to the notation
   2.192  		followed by a right parenthesis.
   2.193  		White space is allowed, but optional, immediately inside the parentheses.
   2.194 -		If a function takes a list of arguments, 
   2.195 -		the arguments are separated by a comma (',') 
   2.196 +		If a function takes a list of arguments,
   2.197 +		the arguments are separated by a comma (',')
   2.198  		with optional whitespace before and after the comma.
   2.199  
   2.200  	<pre class="example">
   2.201 @@ -904,8 +905,8 @@
   2.202  Mathematical Expressions: ''calc()''</h3>
   2.203  
   2.204  	<p>The <dfn>calc()</dfn> function
   2.205 -	allows mathematical expressions with addition (''+''), subtraction (''-''), 
   2.206 -	multiplication (''*''), and division (''/'') to be used 
   2.207 +	allows mathematical expressions with addition (''+''), subtraction (''-''),
   2.208 +	multiplication (''*''), and division (''/'') to be used
   2.209  	as component values.  The ''calc()'' expression represents the result of the
   2.210  	mathematical calculation it contains, using standard operator precedence
   2.211  	rules. It can be used wherever
   2.212 @@ -967,9 +968,9 @@
   2.213  
   2.214  		<pre>
   2.215  .foo {
   2.216 -	background-image: linear-gradient(to right, silver, 
   2.217 -	                                            white 50px, 
   2.218 -	                                            white calc(100% - 50px), 
   2.219 +	background-image: linear-gradient(to right, silver,
   2.220 +	                                            white 50px,
   2.221 +	                                            white calc(100% - 50px),
   2.222  	                                            silver);
   2.223  }
   2.224  </pre>
   2.225 @@ -990,12 +991,12 @@
   2.226  attr    : "attr(" S* qname [ S+ type-keyword ]? S* [ "," [ unit | calc ] S* ]? ")";
   2.227  unit    : [ NUMBER | DIMENSION | PERCENTAGE | "(" S* sum S* ")" | calc | attr ];</pre>
   2.228  
   2.229 -	<p class='note'>Note that the grammar requires spaces around binary ''+'' 
   2.230 -	and ''-'' operators.  The ''*'' and ''/'' operators do not require 
   2.231 +	<p class='note'>Note that the grammar requires spaces around binary ''+''
   2.232 +	and ''-'' operators.  The ''*'' and ''/'' operators do not require
   2.233  	spaces.</p>
   2.234  
   2.235  	<p>Additionally, the following redefinition is made to the informative
   2.236 -	grammar appearing in 
   2.237 +	grammar appearing in
   2.238  	<a href="http://www.w3.org/TR/CSS2/grammar.html">CSS 2.1 Appendix G</a>:</p>
   2.239  
   2.240  	<pre>
   2.241 @@ -1007,9 +1008,9 @@
   2.242    ;</pre>
   2.243  
   2.244  	<p>
   2.245 -		UAs must support ''calc()'' expressions of at least 20 terms, 
   2.246 -		where each <code>NUMBER</code>, <code>DIMENSION</code>, or <code>PERCENTAGE</code> is a term.  
   2.247 -		If a ''calc()'' expression contains more than the supported number of terms, 
   2.248 +		UAs must support ''calc()'' expressions of at least 20 terms,
   2.249 +		where each <code>NUMBER</code>, <code>DIMENSION</code>, or <code>PERCENTAGE</code> is a term.
   2.250 +		If a ''calc()'' expression contains more than the supported number of terms,
   2.251  		it must be treated as if it were invalid.
   2.252  
   2.253  
   2.254 @@ -1018,22 +1019,22 @@
   2.255  
   2.256  	<p>
   2.257  		A math expression has a <dfn>resolved type</dfn>, which is one of
   2.258 -		<var>&lt;length></var>, 
   2.259 -		<var>&lt;frequency></var>, 
   2.260 -		<var>&lt;angle></var>, 
   2.261 +		<var>&lt;length></var>,
   2.262 +		<var>&lt;frequency></var>,
   2.263 +		<var>&lt;angle></var>,
   2.264  		<var>&lt;time></var>,
   2.265  		<var>&lt;number></var>, or
   2.266 -		<var>&lt;integer></var>.  
   2.267 -		The <i>resolved type</i> must be valid for where the expression is placed; 
   2.268 -		otherwise, the expression is invalid. 
   2.269 -		The <i>resolved type</i> of the expression is determined by the types of the values it contains. 
   2.270 +		<var>&lt;integer></var>.
   2.271 +		The <i>resolved type</i> must be valid for where the expression is placed;
   2.272 +		otherwise, the expression is invalid.
   2.273 +		The <i>resolved type</i> of the expression is determined by the types of the values it contains.
   2.274  		<code>NUMBER</code> tokens are of type <var>&lt;number></var> or <var>&lt;integer></var>.
   2.275 -		A <code>DIMENSION</code> token's type is given by its unit 
   2.276 +		A <code>DIMENSION</code> token's type is given by its unit
   2.277  		(''cm'' is <var>&lt;length></var>, ''deg'' is <var>&lt;angle></var>, etc.).
   2.278  		An ''attr()'' expression's type is given by its <var>&lt;type-or-unit></var> argument.
   2.279 -		If percentages are accepted in the context in which the expression is placed, 
   2.280 -		a <code>PERCENTAGE</code> token has the type of the value that percentages are relative to; 
   2.281 -		otherwise, 
   2.282 +		If percentages are accepted in the context in which the expression is placed,
   2.283 +		a <code>PERCENTAGE</code> token has the type of the value that percentages are relative to;
   2.284 +		otherwise,
   2.285  		a math expression containing percentages is invalid.</p>
   2.286  
   2.287  	<p>Operators form sub-expressions, which gain types based on their arguments.
   2.288 @@ -1045,7 +1046,7 @@
   2.289  
   2.290  	<ul>
   2.291  		<li>
   2.292 -			At '','', ''+'', or ''-'', 
   2.293 +			At '','', ''+'', or ''-'',
   2.294  			check that both sides have the same type,
   2.295  			or that one side is a <var>&lt;number></var> and the other is an <var>&lt;integer></var>.
   2.296  			If both sides are the same type,
   2.297 @@ -1054,7 +1055,7 @@
   2.298  			resolve to <var>&lt;number></var>.
   2.299  
   2.300  		<li>
   2.301 -			At ''*'', 
   2.302 +			At ''*'',
   2.303  			check that at least one side is <var>&lt;number></var>.
   2.304  			If both sides are <var>&lt;integer></var>,
   2.305  			resolve to <var>&lt;integer></var>.
   2.306 @@ -1062,7 +1063,7 @@
   2.307  			resolve to the type of the other side.
   2.308  
   2.309  		<li>
   2.310 -			At ''/'', 
   2.311 +			At ''/'',
   2.312  			check that the right side is <var>&lt;number></var>.
   2.313  			If the left side is <var>&lt;integer></var>,
   2.314  			resolve to <var>&lt;number></var>.
   2.315 @@ -1071,9 +1072,9 @@
   2.316  	</ul>
   2.317  
   2.318  	<p>If an operator does not pass the above checks, the expression is invalid.
   2.319 -	Also, division by zero is invalid.  This includes both dividing by the 
   2.320 +	Also, division by zero is invalid.  This includes both dividing by the
   2.321  	literal number zero, as well as any numeric expression that evaluates to zero
   2.322 -	(as purely-numeric expressions can be evaluated without any additional 
   2.323 +	(as purely-numeric expressions can be evaluated without any additional
   2.324  	information at parse time).</p>
   2.325  
   2.326  	<p class='note'>
   2.327 @@ -1098,22 +1099,22 @@
   2.328  		If there are special rules for computing percentages in a value
   2.329  		(e.g. <a href="http://www.w3.org/TR/CSS21/visudet.html#the-height-property">the 'height' property</a>),
   2.330  		they apply whenever a ''calc()'' expression contains percentages.
   2.331 -		
   2.332 +
   2.333  	<p class='note'>
   2.334  		Thus, the computed value of a ''calc()'' expression can be represented
   2.335  		as either a number
   2.336  		or a tuple of a dimension and a percentage.
   2.337  
   2.338  	<!-- http://lists.w3.org/Archives/Public/www-style/2010May/0001.html
   2.339 -	This has notes on how we should handle things when calc() is extended to 
   2.340 +	This has notes on how we should handle things when calc() is extended to
   2.341  	handle unit mult/div. Related to this is <unit>mod<unit>, which can return
   2.342  	0 and thus introduce computed-time division-by-zero. -->
   2.343  
   2.344  	<p>
   2.345 -		Given the complexities of width and height calculations on table cells and table elements, 
   2.346 -		math expressions involving percentages for widths and heights on 
   2.347 -		table columns, table column groups, table rows, table row groups, and table cells 
   2.348 -		in both auto and fixed layout tables 
   2.349 +		Given the complexities of width and height calculations on table cells and table elements,
   2.350 +		math expressions involving percentages for widths and heights on
   2.351 +		table columns, table column groups, table rows, table row groups, and table cells
   2.352 +		in both auto and fixed layout tables
   2.353  		MAY be treated as if ''auto'' had been specified.
   2.354  
   2.355  
   2.356 @@ -1121,7 +1122,7 @@
   2.357  Range Checking</h4>
   2.358  
   2.359  	<p>The value resulting from an expression must be clamped to the
   2.360 -	range allowed in the target context.  
   2.361 +	range allowed in the target context.
   2.362  
   2.363  	<p class="note">Note this requires all contexts accepting ''calc()''
   2.364  	to define their allowable values as a closed (not open) interval.
   2.365 @@ -1153,10 +1154,10 @@
   2.366  	<pre>toggle( &lt;value><a href="#component-multipliers">#</a> )</pre>
   2.367  
   2.368  	<p>
   2.369 -		where <var>&lt;value></var> is any CSS value 
   2.370 +		where <var>&lt;value></var> is any CSS value
   2.371  		that is valid where the expression is placed,
   2.372 -		and that doesn't contain any top-level commas.  
   2.373 -		If any of the values inside are not valid, 
   2.374 +		and that doesn't contain any top-level commas.
   2.375 +		If any of the values inside are not valid,
   2.376  		then the entire ''toggle()'' expression is invalid.
   2.377  		The ''toggle()'' expression may be used as the value of any property
   2.378  		(but must be the only component in that property's value).
   2.379 @@ -1171,16 +1172,16 @@
   2.380  		Declarations containing such constructs are invalid.</p>
   2.381  
   2.382  	<p>
   2.383 -		The value represented by ''toggle()'' is determined 
   2.384 -		by comparing the inherited value <var>I</var> 
   2.385 -		(i.e. the <a href="http://www.w3.org/TR/CSS21/cascade.html#computed-value">computed value</a> on the parent, 
   2.386 -		or, for the root, the initial value) 
   2.387 +		The value represented by ''toggle()'' is determined
   2.388 +		by comparing the inherited value <var>I</var>
   2.389 +		(i.e. the <a href="http://www.w3.org/TR/CSS21/cascade.html#computed-value">computed value</a> on the parent,
   2.390 +		or, for the root, the initial value)
   2.391  		to the computed values <var>C<sub>n</sub></var> returned by the <var>n</var>-th argument to ''toggle()''.
   2.392 -		For the earliest <var>C<sub>n</sub></var> 
   2.393 -		such that <var>C<sub>n</sub></var> = <var>I</var>, 
   2.394 -		the value returned by toggle is <var>C<sub>n+1</sub></var>.  
   2.395 -		However, if this <var>C<sub>n</sub></var> is the last value, 
   2.396 -		or if there are no <var>C<sub>n</sub></var> that equal <var>I</var>, 
   2.397 +		For the earliest <var>C<sub>n</sub></var>
   2.398 +		such that <var>C<sub>n</sub></var> = <var>I</var>,
   2.399 +		the value returned by toggle is <var>C<sub>n+1</sub></var>.
   2.400 +		However, if this <var>C<sub>n</sub></var> is the last value,
   2.401 +		or if there are no <var>C<sub>n</sub></var> that equal <var>I</var>,
   2.402  		the computed value of the first value is returned instead.
   2.403  
   2.404  	<div class='example'>
   2.405 @@ -1228,8 +1229,8 @@
   2.406  	<p>
   2.407  		The computed value of the ''attr()'' expression is the value of the attribute with the specified name on the element, according to the rules given below.
   2.408  
   2.409 -	<p class='note'>In CSS2.1 [[!CSS21]], the ''attr()'' expression always returns a string. 
   2.410 -	In CSS3, the ''attr()'' expression can return many different types. The 
   2.411 +	<p class='note'>In CSS2.1 [[!CSS21]], the ''attr()'' expression always returns a string.
   2.412 +	In CSS3, the ''attr()'' expression can return many different types. The
   2.413  	''attr()'' expression cannot return everything, for example it cannot
   2.414  	do counters, named strings, quotes, or keyword values such as ''auto'',
   2.415  	''nowrap'', or ''baseline''. This is intentional, as the intent of the
   2.416 @@ -1242,14 +1243,14 @@
   2.417  	<pre>attr( &lt;attr-name> &lt;type-or-unit>? [ , &lt;fallback> ]? )</pre>
   2.418  
   2.419  	<p>
   2.420 -		where &lt;attr-name> is a <a href="http://dev.w3.org/csswg/css3-namespace/#css-qnames">CSS qualified name</a> 
   2.421 +		where &lt;attr-name> is a <a href="http://dev.w3.org/csswg/css3-namespace/#css-qnames">CSS qualified name</a>
   2.422  		(the qname production in [[!CSS3NAMESPACE]])
   2.423  		that represents an attribute name.
   2.424  		(In the absence of namespacing, this will just be a CSS identifier.)
   2.425  
   2.426  	<p>
   2.427  		The optional <var>&lt;type-or-unit></var> argument is a keyword drawn from the list below that tells the UA how to interpret the attribute value,
   2.428 -		and defines a type for the attr() expression. 
   2.429 +		and defines a type for the attr() expression.
   2.430  		If omitted, ''string'' is implied.
   2.431  
   2.432  	<p>
   2.433 @@ -1287,8 +1288,8 @@
   2.434  	<div class='note'>
   2.435  		<p>
   2.436  			Note that the default value need not be of the type given,
   2.437 -			if the attr() expression is the entire property value. 
   2.438 -			For instance, if the type required of the attribute by the author is ''px'', 
   2.439 +			if the attr() expression is the entire property value.
   2.440 +			For instance, if the type required of the attribute by the author is ''px'',
   2.441  			the default could still be ''auto'',
   2.442  			like in ''width: attr(size px, auto);''.
   2.443  
   2.444 @@ -1301,12 +1302,12 @@
   2.445  	</div>
   2.446  
   2.447  	<p>
   2.448 -		If the specified attribute exists on the element, 
   2.449 +		If the specified attribute exists on the element,
   2.450  		the value of the attribute must be parsed as required by the <var>&lt;type-or-unit></var> argument
   2.451  		(as defined in the list below).
   2.452  		Unless the type is ''string'', it must first be stripped of leading and trailing white space.
   2.453  		The resulting value is the attr() expression's value.
   2.454 -		If the value did not parse as required, 
   2.455 +		If the value did not parse as required,
   2.456  		the attr() expression's value is its fallback value.
   2.457  
   2.458  	<p>The <var>&lt;type-or-unit></var> keywords are:</p>
   2.459 @@ -1314,7 +1315,7 @@
   2.460  	<dl>
   2.461  		<dt>''string''
   2.462  		<dd>
   2.463 -			The attribute value will be parsed as the contents of a CSS <var>&lt;string></var>. 
   2.464 +			The attribute value will be parsed as the contents of a CSS <var>&lt;string></var>.
   2.465  			The default is the empty string.
   2.466  
   2.467  		<dt>''color''
   2.468 @@ -1325,32 +1326,32 @@
   2.469  
   2.470  		<dt>''url''
   2.471  		<dd>
   2.472 -			The attribute value will be parsed as the contents of a CSS <var>&lt;string></var>. 
   2.473 +			The attribute value will be parsed as the contents of a CSS <var>&lt;string></var>.
   2.474  			It is interpreted as a quoted string within the ''url()'' notation.
   2.475  			The default is ''about:invalid'', which is a URI defined (<a href="#about-invalid">in Appendix A</a>) to point
   2.476 -			to a non-existent document with a generic error condition. 
   2.477 +			to a non-existent document with a generic error condition.
   2.478  			Relative URLs must be made absolute
   2.479 -			according to the rules of the document language as applied to URLs originating from the element; 
   2.480 +			according to the rules of the document language as applied to URLs originating from the element;
   2.481  			they are not relative to the style sheet.
   2.482  
   2.483  		<dt>''integer''
   2.484  		<dd>
   2.485  			The attribute value must parse as a NUMBER CSS token,
   2.486  			and be successfully interpreted as an <var>&lt;integer></var>.
   2.487 -			The default is ''0'', 
   2.488 -			or else the property's minimum value if ''0'' is not valid for the property. 
   2.489 -			The default must also be used 
   2.490 -			if the property in question only accepts integers within a certain range 
   2.491 +			The default is ''0'',
   2.492 +			or else the property's minimum value if ''0'' is not valid for the property.
   2.493 +			The default must also be used
   2.494 +			if the property in question only accepts integers within a certain range
   2.495  			and the attribute is out of range.
   2.496  
   2.497  		<dt>''number''
   2.498  		<dd>
   2.499  			The attribute value must parse as a NUMBER CSS token,
   2.500  			and is interpreted as an <var>&lt;number></var>.
   2.501 -			The default is ''0'', 
   2.502 -			or else the property's minimum value if ''0'' is not valid for the property. 
   2.503 -			The default must also be used 
   2.504 -			if the property in question only accepts integers within a certain range 
   2.505 +			The default is ''0'',
   2.506 +			or else the property's minimum value if ''0'' is not valid for the property.
   2.507 +			The default must also be used
   2.508 +			if the property in question only accepts integers within a certain range
   2.509  			and the attribute is out of range.
   2.510  
   2.511  		<dt>''length''
   2.512 @@ -1360,12 +1361,12 @@
   2.513  		<dd>
   2.514  			The attribute value must parse as a DIMENSION CSS token,
   2.515  			and be successfully interpreted as the specified type.
   2.516 -			The default is ''0'' in the relevant units, 
   2.517 -			or else the property's minimum value if ''0'' in the relevant units is not valid for the property. 
   2.518 -			The default must also be used 
   2.519 -			if the property in question only accepts values within a certain range 
   2.520 -			(e.g. positive lengths or angles from 0 to 90deg) 
   2.521 -			and the attribute is out of range (e.g. a negative length or 180deg). 
   2.522 +			The default is ''0'' in the relevant units,
   2.523 +			or else the property's minimum value if ''0'' in the relevant units is not valid for the property.
   2.524 +			The default must also be used
   2.525 +			if the property in question only accepts values within a certain range
   2.526 +			(e.g. positive lengths or angles from 0 to 90deg)
   2.527 +			and the attribute is out of range (e.g. a negative length or 180deg).
   2.528  			If the unit is a relative length, it must be computed to an absolute length.
   2.529  
   2.530  		<dt>''em''
   2.531 @@ -1392,18 +1393,18 @@
   2.532  		<dd>
   2.533  			The attribute value must parse as a NUMBER CSS token,
   2.534  			and is interpreted as a <i>dimension</i> with the specified unit.
   2.535 -			The default is ''0'' in the relevant units, 
   2.536 -			or else the property's minimum value if ''0'' in the relevant units is not valid for the property. 
   2.537 -			The default must also be used 
   2.538 -			if the property in question only accepts values within a certain range 
   2.539 -			(e.g. positive lengths or angles from 0 to 90deg) 
   2.540 -			and the attribute is out of range (e.g. a negative length or 180deg). 
   2.541 -			If the unit is a relative length, 
   2.542 +			The default is ''0'' in the relevant units,
   2.543 +			or else the property's minimum value if ''0'' in the relevant units is not valid for the property.
   2.544 +			The default must also be used
   2.545 +			if the property in question only accepts values within a certain range
   2.546 +			(e.g. positive lengths or angles from 0 to 90deg)
   2.547 +			and the attribute is out of range (e.g. a negative length or 180deg).
   2.548 +			If the unit is a relative length,
   2.549  			it must be computed to an absolute length.
   2.550  	</dl>
   2.551  
   2.552  	<div class="example">
   2.553 -		<p>This example shows the use of attr() to visually illustrate data 
   2.554 +		<p>This example shows the use of attr() to visually illustrate data
   2.555  		in an XML file:</p>
   2.556  
   2.557  		<pre>
   2.558 @@ -1443,24 +1444,24 @@
   2.559  }-->
   2.560  
   2.561  	<div class="illegal example">
   2.562 -		<p>All of the following examples are invalid and would cause a 
   2.563 -		parse-time error, and thus cause the relevant declaration&mdash;in 
   2.564 +		<p>All of the following examples are invalid and would cause a
   2.565 +		parse-time error, and thus cause the relevant declaration&mdash;in
   2.566  		this case all of them&mdash;to be ignored:</p>
   2.567  
   2.568  		<pre>
   2.569  content: attr(title color); /* 'content' doesn't accept colors */
   2.570  
   2.571 -content: attr(end-of-quote string, inherit) close-quote; 
   2.572 +content: attr(end-of-quote string, inherit) close-quote;
   2.573  /* the 'inherit' value is not allowed there, since the result would be
   2.574  'inherit close-quote', which is invalid. */
   2.575  
   2.576 -margin: attr(vertical length) attr(horizontal deg); 
   2.577 +margin: attr(vertical length) attr(horizontal deg);
   2.578  /* deg units are not valid at that point */
   2.579  
   2.580  color: attr(color); /* 'color' doesn't accept strings */</pre>
   2.581  	</div>
   2.582  
   2.583 -	<p class='note'>The ''attr()'' expression cannot currently fall back onto 
   2.584 +	<p class='note'>The ''attr()'' expression cannot currently fall back onto
   2.585  	another attribute. Future versions of CSS may extend ''attr()'' in this
   2.586  	direction.</p>
   2.587  
   2.588 @@ -1581,21 +1582,21 @@
   2.589    document are to be interpreted as described in RFC 2119.
   2.590    However, for readability, these words do not appear in all uppercase
   2.591    letters in this specification.
   2.592 -  
   2.593 +
   2.594    <p>All of the text of this specification is normative except sections
   2.595    explicitly marked as non-normative, examples, and notes. [[!RFC2119]]</p>
   2.596 -  
   2.597 +
   2.598    <p>Examples in this specification are introduced with the words “for example”
   2.599    or are set apart from the normative text with <code>class="example"</code>,
   2.600    like this:
   2.601 -  
   2.602 +
   2.603    <div class="example">
   2.604      <p>This is an example of an informative example.</p>
   2.605    </div>
   2.606 -  
   2.607 +
   2.608    <p>Informative notes begin with the word “Note” and are set apart from the
   2.609    normative text with <code>class="note"</code>, like this:
   2.610 -  
   2.611 +
   2.612    <p class="note">Note, this is an informative note.</p>
   2.613  
   2.614  <h3 class="no-num" id="conformance-classes">
   2.615 @@ -1615,12 +1616,12 @@
   2.616        <dd>A <a href="http://www.w3.org/TR/CSS21/conform.html#user-agent">UA</a>
   2.617        that writes a style sheet.
   2.618    </dl>
   2.619 -  
   2.620 +
   2.621    <p>A style sheet is conformant to CSS Values and Units Level 3
   2.622    if all of its statements that use syntax defined in this module are valid
   2.623    according to the generic CSS grammar and the individual grammars of each
   2.624    feature defined in this module.
   2.625 -  
   2.626 +
   2.627    <p>A renderer is conformant to CSS Values and Units Level 3
   2.628    if, in addition to interpreting the style sheet as defined by the
   2.629    appropriate specifications, it supports all the features defined
   2.630 @@ -1629,7 +1630,7 @@
   2.631    UA to correctly render a document due to limitations of the device
   2.632    does not make the UA non-conformant. (For example, a UA is not
   2.633    required to render color on a monochrome monitor.)
   2.634 -  
   2.635 +
   2.636    <p>An authoring tool is conformant to CSS Values and Units Level 3
   2.637    if it writes style sheets that are syntactically correct according to the
   2.638    generic CSS grammar and the individual grammars of each feature in
   2.639 @@ -1649,14 +1650,14 @@
   2.640    multi-value property declaration: if any value is considered invalid
   2.641    (as unsupported values must be), CSS requires that the entire declaration
   2.642    be ignored.</p>
   2.643 -  
   2.644 +
   2.645  <h3 class="no-num" id="experimental">
   2.646  Experimental implementations</h3>
   2.647  
   2.648    <p>To avoid clashes with future CSS features, the CSS2.1 specification
   2.649    reserves a <a href="http://www.w3.org/TR/CSS21/syndata.html#vendor-keywords">prefixed
   2.650    syntax</a> for proprietary and experimental extensions to CSS.
   2.651 -  
   2.652 +
   2.653    <p>Prior to a specification reaching the Candidate Recommendation stage
   2.654    in the W3C process, all implementations of a CSS feature are considered
   2.655    experimental. The CSS Working Group recommends that implementations
   2.656 @@ -1664,7 +1665,7 @@
   2.657    W3C Working Drafts. This avoids incompatibilities with future changes
   2.658    in the draft.
   2.659    </p>
   2.660 - 
   2.661 +
   2.662  <h3 class="no-num" id="testing">
   2.663  Non-experimental implementations</h3>
   2.664  
   2.665 @@ -1672,7 +1673,7 @@
   2.666    non-experimental implementations are possible, and implementors should
   2.667    release an unprefixed implementation of any CR-level feature they
   2.668    can demonstrate to be correctly implemented according to spec.
   2.669 -  
   2.670 +
   2.671    <p>To establish and maintain the interoperability of CSS across
   2.672    implementations, the CSS Working Group requests that non-experimental
   2.673    CSS renderers submit an implementation report (and, if necessary, the
   2.674 @@ -1680,7 +1681,7 @@
   2.675    releasing an unprefixed implementation of any CSS features. Testcases
   2.676    submitted to W3C are subject to review and correction by the CSS
   2.677    Working Group.
   2.678 -  
   2.679 +
   2.680    <p>Further information on submitting testcases and implementation reports
   2.681    can be found from on the CSS Working Group's website at
   2.682    <a href="http://www.w3.org/Style/CSS/Test/">http://www.w3.org/Style/CSS/Test/</a>.
   2.683 @@ -1698,14 +1699,14 @@
   2.684    products, there is no requirement that all features be implemented by
   2.685    a single product. For the purposes of this criterion, we define the
   2.686    following terms:
   2.687 -  
   2.688 +
   2.689    <dl>
   2.690      <dt>independent <dd>each implementation must be developed by a
   2.691      different party and cannot share, reuse, or derive from code
   2.692      used by another qualifying implementation. Sections of code that
   2.693      have no bearing on the implementation of this specification are
   2.694      exempt from this requirement.
   2.695 -  
   2.696 +
   2.697      <dt>interoperable <dd>passing the respective test case(s) in the
   2.698      official CSS test suite, or, if the implementation is not a Web
   2.699      browser, an equivalent test. Every relevant test in the test
   2.700 @@ -1716,32 +1717,32 @@
   2.701      equivalent tests in the same way for the purpose of
   2.702      interoperability. The equivalent tests must be made publicly
   2.703      available for the purposes of peer review.
   2.704 -  
   2.705 +
   2.706      <dt>implementation <dd>a user agent which:
   2.707 -  
   2.708 +
   2.709      <ol class=inline>
   2.710        <li>implements the specification.
   2.711 -  
   2.712 +
   2.713        <li>is available to the general public. The implementation may
   2.714        be a shipping product or other publicly available version
   2.715 -      (i.e., beta version, preview release, or “nightly build”). 
   2.716 +      (i.e., beta version, preview release, or “nightly build”).
   2.717        Non-shipping product releases must have implemented the
   2.718        feature(s) for a period of at least one month in order to
   2.719        demonstrate stability.
   2.720 -  
   2.721 +
   2.722        <li>is not experimental (i.e., a version specifically designed
   2.723        to pass the test suite and is not intended for normal usage
   2.724        going forward).
   2.725      </ol>
   2.726    </dl>
   2.727 -  
   2.728 +
   2.729    <p>The specification will remain Candidate Recommendation for at least
   2.730    six months.
   2.731  
   2.732  <h2 class="no-num" id="changes">Changes</h2>
   2.733  
   2.734    <p>Changes since the <a href="http://www.w3.org/TR/2012/CR-css3-values-20120828/">28 August Candidate Recommendation</a> are:
   2.735 -  
   2.736 +
   2.737    <ul>
   2.738      <li>Corrected <code>wqname</code> in the ''attr()'' syntax to <code>qname</code>
   2.739      <li>Made undefined namespace prefixes in ''attr()'' invalidate the function.

mercurial