Skip to content

Conversation

k1w1
Copy link

@k1w1 k1w1 commented Aug 22, 2022

Support filling and stroking paths. Allows code like:

const path = ctx.createPath(`M 230 80
    A 45 45, 0, 1, 0, 275 125
    L 275 80 Z`);

ctx.strokeStyle = 'red';
ctx.stroke(path);

Fixes #20

k1w1 and others added 18 commits July 15, 2022 17:57
Fix rendering of arcTo when a scale is applied
Bring in changes from zenozeng/svgcanvas
Otherwise the SVGs we generate can't be opened by editing tools like Figma.
…ion in the test, but not for lines curving in other directions.
However this is not correctly handling the transform. To do it correctly we need to store the sub-paths in the path in their original form (not a string) and apply the transforms at render time.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Calling Context.fill with a path does not work

1 participant