Onpaint madness

63q2o4i02 at sneakemail.com 63q2o4i02 at sneakemail.com
Sat Sep 2 13:44:25 PDT 2006


Vadim Zeitlin wrote:
> On 1 Sep 2006 18:49:54 -0700 63q2o4i02 at sneakemail.com wrote:
>
> > I'm getting a zillion OnPaint messages with no luck in trynig to handle
> > them.
>
>  The most likely reason is that you don't create wxPaintDC for the window
> which must be repainted and so it remains invalidated resulting in more
> paint events being sent.
>

Yes, I've tried creating even a dummy wxPaintDC, but it still won't
stop sending messages to the frame.  Should each subwindow have its own
class and therefore its own OnPaint handler?  Right now I'm letting the
frame handle the message and then draw on the subwindows directly.
Perhaps this is causing them to generate a new paint message, but since
there is no subwindow handler it goes right back to the Frame?

thanks
ms







More information about the wx-users mailing list