JithinKS97 / dynamic-learning

A platform where teachers collaborate with creative coders to make STEM lessons that make use of interactive visualisations
https://dynamic-learning.herokuapp.com/
GNU Lesser General Public License v2.1
31 stars 23 forks source link

Adding an eraser tool in workbookeditor page #75

Open annu12340 opened 5 years ago

annu12340 commented 5 years ago

Screenshot (3)

At present, the slides only have an option to clear the entire canvas. There is no tool to erase certain parts of the slide

JithinKS97 commented 5 years ago

Interestingly, previously we had eraser tool when we used the js library called drawingboard.js for implementing the drawing functionality https://leimi.github.io/drawingboard.js/

But then we shifted to fabric.js http://fabricjs.com/ where the implementation of eraser was a bit tricky

annu12340 commented 5 years ago

ok What are the unique features of fabric.js? Why was there a shift from https://leimi.github.io/drawingboard.js/ to http://fabricjs.com/ ?

JithinKS97 commented 5 years ago

drawingboardjs is very primitive with only brush tool. But fabric.js is much advanced with a lot of other functionalities. For example, drawing and manipulation of shapes. Even though there is no eraser in fabric js, it is possible to select the strokes and delete them which I though would serve the purpose anyway.