update in canvaswrapper and index