fixes to canvas draw