jweinst1 / Oblivion

The language of Art
https://jweinst1.github.io/OblivionWebsite/
MIT License
413 stars 16 forks source link

[Suggestion from Reddit] Change meaning of arrows #10

Closed Fordi closed 1 month ago

Fordi commented 7 years ago

It seems like the distinction between stroke/fill is in the wrong place; stroke/fill are properties of the path, not its elements. A better purpose for arrow variants would be type of path element, e.g.,

arrow meaning
> X, Y move to X, Y
-> X, Y line to X, Y
c> X, Y smooth quadratic curve to X, Y
c> cX, cY X, Y quadratic curve to X, Y with control point cX, cY
~> cX, cY X, Y smooth cubic curve to X, Y with control point cX, cY
~> sX, sY eX, eY X, Y cubic curve to X, Y with leading control point sX, sY and trailing control point eX, eY
-I Y vertical line to Y
-- X horizontal line to X
o> rX, rY X,Y clockwise large-sweep arc to X, Y with radius rX, rY
<o rX, rY X,Y counter-clockwise large-sweep arc to X, Ywith radius rX, rY
o< rX, rY X,Y clockwise small-sweep arc to X, Ywith radius rX, rY
>o rX, rY X,Y counter-clockwise small-sweep arc to X, Ywith radius rX, rY