Difference between revisions of "OpenDocument SVG Correspondence"

From Inkscape Wiki
Jump to navigation Jump to search
(* Comment on width,height,x,y attributes)
(* polygons. Some work on Common Drawing Shape Attributes)
Line 18: Line 18:
svg:points attribute: points.  The OpenDocument specification is (at first glance at least) ambiguous as to whether coordinates can contain units, whereas the SVG spec disallows units.
svg:points attribute: points.  The OpenDocument specification is (at first glance at least) ambiguous as to whether coordinates can contain units, whereas the SVG spec disallows units.


The OpenDocument standard allows specifying a svg:width and/or svg:height attribute, but says that these "may" be ignored. The SVG 1.1 standard does not allow specifying width or height attributes other than for rect, image, foreignObject, and a few other things (see http://www.w3.org/TR/SVG11/attindex.html).
==== 9.2.4 Polygon ====


Similarly, the OpenDocument standard allows specifying svg:x and svg:y attributes (though doesn't mention their interpretation; probably ignored); whereas the SVG 1.1 spec allows x and y attributes on only a few elements (typically those that don't otherwise specify their position).
draw:polygon element: svg:polygon
 
==== 9.2.5 Regular Polygon ====
 
draw:regular-polygon element: svg:path supplemented by draw:blah attributes used as hints to editing programs (similar to the star tool in inkscape).
 
Consider hinting only what cannot be inferred from the path data, to reduce problems from conflicts between the path data and hints.
 
==== 9.2.15 Common Drawing Shape Attributes ====
 
===== Name =====
 
The OpenDocument specification doesn't mention the interpretation or use of its draw:name attribute.
Probably it's a human-readable name used only in dialog boxes of editors for OpenDocument documents.
If so, then it can stay as draw:name, and can safely be ignored by most SVG user agents.
 
===== Position =====
 
The OpenDocument standard allows specifying svg:x and svg:y attributes (though in some cases doesn't mention their interpretation; probably ignored); whereas the SVG 1.1 spec allows x and y attributes on only a few elements (typically those that don't otherwise specify their position).
 
===== Size =====
 
The OpenDocument standard allows specifying a svg:width and/or svg:height attribute for many shapes, typically saying that these attributes "may" be ignored.  The SVG 1.1 standard does not allow specifying width or height attributes other than for rect, image, foreignObject, and a few other things (see http://www.w3.org/TR/SVG11/attindex.html).
 
===== Unfinished: Transformation onwards =====

Revision as of 01:30, 1 February 2005

Section 9.2 (pp275-) of the OpenDocument specification (available at http://www.oasis-open.org/committees/tc_home.php?wg_abbrev=office) is the most obviously related to SVG.

9.2 Drawing Shapes

9.2.1 Rectangle

draw:rect element: svg:rect (http://www.w3.org/TR/SVG11/shapes.html#RectElement)

draw:corner-radius attribute: rx. (OpenDocument has no equivalent of specifying both rx and ry, so we may forbid specifying ry in OpenDocument SVG fragments.)

9.2.2 Line

draw:line element: svg:line (http://www.w3.org/TR/SVG11/shapes.html#LineElement)

9.2.3 Polyline

draw:polyline element: svg:polyline (http://www.w3.org/TR/SVG11/shapes.html#PolylineElement)

svg:points attribute: points. The OpenDocument specification is (at first glance at least) ambiguous as to whether coordinates can contain units, whereas the SVG spec disallows units.

9.2.4 Polygon

draw:polygon element: svg:polygon

9.2.5 Regular Polygon

draw:regular-polygon element: svg:path supplemented by draw:blah attributes used as hints to editing programs (similar to the star tool in inkscape).

Consider hinting only what cannot be inferred from the path data, to reduce problems from conflicts between the path data and hints.

9.2.15 Common Drawing Shape Attributes

Name

The OpenDocument specification doesn't mention the interpretation or use of its draw:name attribute. Probably it's a human-readable name used only in dialog boxes of editors for OpenDocument documents. If so, then it can stay as draw:name, and can safely be ignored by most SVG user agents.

Position

The OpenDocument standard allows specifying svg:x and svg:y attributes (though in some cases doesn't mention their interpretation; probably ignored); whereas the SVG 1.1 spec allows x and y attributes on only a few elements (typically those that don't otherwise specify their position).

Size

The OpenDocument standard allows specifying a svg:width and/or svg:height attribute for many shapes, typically saying that these attributes "may" be ignored. The SVG 1.1 standard does not allow specifying width or height attributes other than for rect, image, foreignObject, and a few other things (see http://www.w3.org/TR/SVG11/attindex.html).

Unfinished: Transformation onwards