fixing redraw (work in progress)