W3C home > Mailing lists > Public > public-css-commits@w3.org > October 2011

csswg/css3-values Overview.html,1.108,1.109 Overview.src.html,1.111,1.112

From: Tab Atkins Jr.. via cvs-syncmail <cvsmail@w3.org>
Date: Mon, 10 Oct 2011 22:59:30 +0000
To: public-css-commits@w3.org
Message-Id: <E1RDOok-00070c-KP@lionel-hutz.w3.org>
Update of /sources/public/csswg/css3-values
In directory hutz:/tmp/cvs-serv26921

Modified Files:
	Overview.html Overview.src.html 
Log Message:
Tweak calc() grammar to resolve tracker issue 149: http://www.w3.org/Style/CSS/Tracker/issues/149

Index: Overview.html
===================================================================
RCS file: /sources/public/csswg/css3-values/Overview.html,v
retrieving revision 1.108
retrieving revision 1.109
diff -u -d -r1.108 -r1.109
--- Overview.html	10 Oct 2011 22:41:43 -0000	1.108
+++ Overview.html	10 Oct 2011 22:59:28 -0000	1.109
@@ -1341,14 +1341,28 @@
    and prose below.
 
   <pre>
-S       : calc | min | max;
-calc    : "calc(" S* sum ")" S*;
-min     : "min(" S* sum [ "," S* sum ]* ")" S*;
-max     : "max(" S* sum [ "," S* sum ]* ")" S*;
-sum     : product [ [ "+" | "-" ] S* product ]*;
-product : unit [ [ "*" | "/" | "mod" ] S* unit ]*;
-unit    : ["+"|"-"]? [ NUMBER S* | DIMENSION S* | PERCENTAGE S* |
-          min | max | "(" S* sum ")" S* ];</pre>
+math    : [ calc | min | max ] S*;
+calc    : "calc(" S* sum S* ")";
+min     : "min(" S* sum [ "," S* sum ]* S* ")";
+max     : "max(" S* sum [ "," S* sum ]* S* ")";
+sum     : product [ S+ [ "+" | "-" ] S+ product ]*;
+product : unit [ S* [ "*" | "/" | "mod" ] S* unit ]*;
+unit    : ["+"|"-"]? [ NUMBER | DIMENSION | PERCENTAGE |
+          min | max | "(" S* sum S* ")" ];</pre>
+
+  <div class=note>
+   <p>Additionally, the following redefinition is made to the informative
+    grammar appearing in <a href="http://www.w3.org/TR/CSS2/grammar.html">CSS
+    2.1 Appendix G</a>:</p>
+
+   <pre>
+term
+  : unary_operator?
+    [ NUMBER S* | PERCENTAGE S* | LENGTH S* | EMS S* | EXS S* | ANGLE S* |
+      TIME S* | FREQ S* ]
+  | STRING S* | IDENT S* | URI S* | hexcolor | function<ins> | math</ins>
+  ;</pre>
+  </div>
 
   <p>The context of the expression imposes a target type, which is one of
    length, frequency, angle, time, or number. NUMBER tokens are of type

Index: Overview.src.html
===================================================================
RCS file: /sources/public/csswg/css3-values/Overview.src.html,v
retrieving revision 1.111
retrieving revision 1.112
diff -u -d -r1.111 -r1.112
--- Overview.src.html	10 Oct 2011 22:41:43 -0000	1.111
+++ Overview.src.html	10 Oct 2011 22:59:28 -0000	1.112
@@ -908,14 +908,28 @@
 	the grammar and prose below.
 
 	<pre>
-S       : calc | min | max;
-calc    : "calc(" S* sum ")" S*;
-min     : "min(" S* sum [ "," S* sum ]* ")" S*;
-max     : "max(" S* sum [ "," S* sum ]* ")" S*;
-sum     : product [ [ "+" | "-" ] S* product ]*;
-product : unit [ [ "*" | "/" | "mod" ] S* unit ]*;
-unit    : ["+"|"-"]? [ NUMBER S* | DIMENSION S* | PERCENTAGE S* |
-          min | max | "(" S* sum ")" S* ];</pre>
+math    : [ calc | min | max ] S*;
+calc    : "calc(" S* sum S* ")";
+min     : "min(" S* sum [ "," S* sum ]* S* ")";
+max     : "max(" S* sum [ "," S* sum ]* S* ")";
+sum     : product [ S+ [ "+" | "-" ] S+ product ]*;
+product : unit [ S* [ "*" | "/" | "mod" ] S* unit ]*;
+unit    : ["+"|"-"]? [ NUMBER | DIMENSION | PERCENTAGE |
+          min | max | "(" S* sum S* ")" ];</pre>
+
+	<div class='note'>
+		<p>Additionally, the following redefinition is made to the informative
+		grammar appearing in 
+		<a href="http://www.w3.org/TR/CSS2/grammar.html">CSS 2.1 Appendix G</a>:</p>
+
+		<pre>
+term
+  : unary_operator?
+    [ NUMBER S* | PERCENTAGE S* | LENGTH S* | EMS S* | EXS S* | ANGLE S* |
+      TIME S* | FREQ S* ]
+  | STRING S* | IDENT S* | URI S* | hexcolor | function<ins> | math</ins>
+  ;</pre>
+	</div>
 
 	<p>The context of the expression imposes a target type, which is one
 	of length, frequency, angle, time, or number. NUMBER tokens are of
Received on Monday, 10 October 2011 22:59:36 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 10 October 2011 22:59:42 GMT