I've got a Canvas which manipulates objects in the mouse event handler. After modifying the objects, I want to trigger the OnPaint() event for the same Canvas to show (rerender) the changes. What is the right way to do this? It doesn't let me call OnPaint() directly. Also, is triggering an event from another event "wrong" in some sense, or likely to lead to trouble?
I would just call self.Refresh() or maybe RefreshRect() and pass the area that needs to be repainted.
Force repaint in wxPython Canvas