Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

CSS jQuery Basics (2014) Creating a Simple Drawing Application Perfect

Personal addition not working perfectly

Hello everybody ! I wanted to practise a bit what I learned, so I added some functionalities to the app like :

  • Clear Canvas
  • Delete Selected
  • Change background Color
  • Rubber
  • Change rubber and pencils stroke size

But, when I change the stroke size on context.lineWidth, its not looking pretty at all when then line gets bigger. There are many little blancs in the line because it creates many little parts of lines i guess... Is there nay way to solve that ?

If you need any extra info please ask !

1 Answer

Sean T. Unwin
Sean T. Unwin
28,690 Points

If I understand your question, you want to enhance the curvature of your lines.

This StackOverflow discussion is good with regards to that.

I also found this tutorial. There are some other interesting tutorials on that site for canvas.

It's a bit too complicated for me, I don't really understand what I have to do :(