How to use the canvas widget