Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

closePath operation #43

Open
hasko opened this issue Jan 28, 2024 · 1 comment
Open

closePath operation #43

hasko opened this issue Jan 28, 2024 · 1 comment

Comments

@hasko
Copy link

hasko commented Jan 28, 2024

When drawing a path, to fill it, it seems I have to add the first point at the end again. The closePath function does that in JS. I would like an equivalent in the elm-canvas package. Or did I miss something?

@mbylstra
Copy link

mbylstra commented Jul 9, 2024

A related issue is that as far as I can tell, if you don't use closePath in the Canvas JS API then this creates artifacts if you want a fully closed shape. Eg: if you make a hexagon, and give it a stroke width of 10 pixels, then the path doesn't properly close and you get an ugly glitch where the path starts and stops.

image

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

No branches or pull requests

2 participants