Graphics-FX/modules/2D-transforms/spec ChangeLog,NONE,1.1 2DTransforms.html,1.4,1.5

Update of /sources/public/Graphics-FX/modules/2D-transforms/spec
In directory hutz:/tmp/cvs-serv27865

Modified Files:
	2DTransforms.html 
Added Files:
	ChangeLog 
Log Message:
2010-12-09 Simon Fraser simon.fraser@apple.com
Add rough drafts for interface for Point, and supplemental interface on Element for point conversion.

Index: 2DTransforms.html
===================================================================
RCS file: /sources/public/Graphics-FX/modules/2D-transforms/spec/2DTransforms.html,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- 2DTransforms.html	14 Oct 2010 05:46:02 -0000	1.4
+++ 2DTransforms.html	9 Dec 2010 19:26:03 -0000	1.5
@@ -932,15 +932,93 @@
 <div id="sec-DOMInterfaces">
   <h2 id="DOMInterfaces">DOM interfaces</h2>
 
-  <div class="note">
-  The interfaces below will be made available in a IDL file for an upcoming draft.
-  </div>
-
-  <p>The following interfaces are defined below: <a href="#RandomInterface">RandomInterface</a>.</p>
+  <p>The following interfaces are defined below: <a href="#PointInterface">Point</a>.</p>
   <br></br>
 
-  <h3 id="RandomInterface">Interface <span class="DOMInterfaceName">RandomInterface</span></h3>
+  <p class="note">
+  These should probably move into the <a href="http://www.w3.org/TR/cssom-view/">CSSOM View Module</a> eventually.
+  </p>
+  
+  <p class="note">
+    Include a class that similar to CSSMatrix/SVGTransform here.
+  </p>
+
+  <h3 id="PointInterface">Interface <span class="DOMInterfaceName">Point</span></h3>
 
+  <p>The <span class="DOMInterfaceName">Point</span> interface contains X and Y coordinates
+    for a point on a 2D plane.</p>
+  <p class="specissue">
+  "Point" needs a prefix to avoid conflicting with lots of existing JavaScript. How does this relate to SVGPoint?
+  What's a good name: WebPoint? ClientPoint (even though it's not always in client coordinates)? CSSPoint? We should probably say something about units
+  here too, and maybe even add a section on coordinate spaces in CSS and SVG.
+  </p>
+  <dl>
+    <dt><br></br>
+    <b>IDL Definition</b></dt>
+      <dd>
+        <div class="idl-code">
+        <pre>interface Point { 
+    readonly attribute long x;
+    readonly attribute long y;
+  };</pre>
+        </div>
+        <br></br>
+      </dd>
+    <dt><b>Attributes</b></dt>
+      <dd><dl>
+          <dt><span class="dom-readonly">readonly</span> <span class="dom-attr-type">long</span> <span class="dom-attr-name">x</span></dt>
+            <dd>The X coordinate of the point.</dd>
+          <dt><span class="dom-readonly">readonly</span> <span class="dom-attr-type">long</span> <span class="dom-attr-name">y</span></dt>
+            <dd>The Y coordinate of the point.</dd>
+        </dl>
+      </dd>
+  </dl>
+
+  <h3 id="TransformableElement">Extensions to the <span class="DOMInterfaceName">Element</span> Interface</h3>
+  
+  <p>These extensions so the <span class="DOMInterfaceName">Element</span> interface
+  are implemented by all SVG and HTML elements, and provide the author a way to convert
+  points between the coordinate spaces of different elements, taking transforms into account.</p>
+  <p>
+  In CSS, the local coordinate system of an element is defined in CSS pixels, with the origin at the top, left
+  corner of the border box, with positive values down and to the right.
+  </p>
+  <p class="specissue">
+    What is the best behavior for inline elements, that may be split over multiple lines?
+  </p>
+  <p>
+  In CSS, the client coordinate system is defined by the CSS viewport. [Need Terminology section.]
+  <!-- The terms viewport, initial containing block are defined by CSS 2.1 unless there's an ancestor foreignObject element in the http://www.w3.org/2000/svg namespace in which case that element acts as viewport and initial containing block. [CSS21] [SVG] -->
+  </p>
+  <p>
+  In SVG, the local coordinate system is defined by ... [WRITE ME].
+  </p>
+  <p>
+  In SVG, the client coordinate system is defined by ... [WRITE ME].
+  </p>
+  <dl>
+    <dt><br></br>
+    <b>IDL Definition</b></dt>
+      <dd>
+        <div class="idl-code">
+        <pre>[Supplemental] interface Element : Element { 
+    Point clientToElement(Point p);
+    Point elementToClient(Point p);
+  };</pre>
+        </div>
+        <br></br>
+      </dd>
+    <dt><b>Methods</b></dt>
+      <dd><dl>
+          <dt><span class="dom-parameter-type">Point</span> <span class="dom-method-name">clientToLocalPoint</span>(<span class="dom-parameter-type">Point</span> <span class="dom-parameter-name">point</span>)</dt>
+            <dd>Convert the given point from Client coordinates into the local coordinate space of the element.</dd>
+            <dt><span class="dom-parameter-type">Point</span> <span class="dom-method-name">localToClientPoint</span>(<span class="dom-parameter-type">Point</span> <span class="dom-parameter-name">point</span>)</dt>
+              <dd>Convert the given point from the local coordinate space of this element into Client coordinates.</dd>
+        </dl>
+      </dd>
+  </dl>
+
+  <h3 id="RandomInterface">Interface <span class="DOMInterfaceName">RandomInterface</span></h3>
 
   <p>The <span class="DOMInterfaceName">RandomInterface</span> interface
   corresponds to the <span class="element-name">'RandomInterface'</span>
@@ -963,6 +1041,7 @@
         </dl>
       </dd>
   </dl>
+
 </div>
 
 

--- NEW FILE: ChangeLog ---
2010-12-09 Simon Fraser simon.fraser@apple.com
	Add rough drafts for interface for Point, and supplemental interface on Element for point conversion.

Received on Thursday, 9 December 2010 19:26:07 UTC