[svgwg] Issue: Proposal for addition of new commands in the Path Data language marked as Proposal

dirkschulze has just labeled an issue for https://github.com/w3c/svgwg as "Proposal":

== Proposal for addition of new commands in the Path Data language ==
The [SVG path data language](https://www.w3.org/TR/SVG/paths.html#PathDataGeneralInformation)  provides a simple way for describing complex geometries. 

I have authored the [Win2d Mini Language specification](https://github.com/ratishphilip/CompositionProToolkit/blob/master/Win2d%20Mini%20Language%20Specification/Win2d%20Mini%20Language%20Specification.pdf) (which is based on the SVG Path data language). It has been implemented to create geometries using the [Win2d](https://github.com/Microsoft/Win2D) library and the Windows 10 Composition layer. The Win2d Mini Language specification consists of several other commands (apart from the SVG path commands) which can be used to specify geometries of common figures and color and brushes etc.

I would like to propose the addition of the following commands in the Path data for SVG which can be useful for creating figures easily 

 **Ellipse Figure**

 | Command | Parameter|
 |---|---|
 | **O** (absolute) or **o** (relative)| **(radiusX radiusY x y)+** |

 Adds an Ellipse figure to the path. The **radiusX** and **radiusY** parameters denote the elliptical radii on the x-axis and y-axis respectively. (**x y**) denotes the center of the ellipse. The current point remains unchanged.

 **Polygon Figure**

 | Command | Parameter|
 |---|---|
 | **P** (absolute) or **p** (relative)| **(numSides radius x y)+** |

 Adds a n-sided Polygon figure to the path. The **radius** parameter denotes the elliptical radii on the x-axis and y-axis respectivelyhe radius of the circle circumscribing the polygon vertices. (**x y**) denotes the center of the polygon. The current point remains unchanged.

 **Rectangle Figure**

 | Command | Parameter|
 |---|---|
 | **R** (absolute) or **r** (relative)| **(x y width height)+** |

 Adds a Rectangle figure to the path. (**x y**) denotes the top-left corner of the rectangle. The current point remains unchanged.

 **RoundedRectangle Figure**

 | Command | Parameter|
 |---|---|
 | **U** (absolute) or **u** (relative)| **(x y width height radiusX radiusY)+** |

 Adds a RoundedRectangle figure to the path. (**x y**) denotes the top-left corner of the rectangle. **radiusX** and **radiusY** denote the radii of the corner curves on the x-axis and y-axis respectively. The current point remains unchanged.



See https://github.com/w3c/svgwg/issues/572

Received on Tuesday, 6 November 2018 05:34:28 UTC