In the onMouseMove definition, view.invalidate match better. (I've seen that thanks to an old post from Jim)
def onMouseMove(flags, x, y, view)
view.invalidate
end
I don't really understand why in deactivate(view) refresh makes it and not in onMouseMove. Nevermind.
It's now easy to follow the mouse move and to replace the cursor with the .draw method.
Thanks again!