canvas: update the code to work on master