Re: re drawing question
Phil <[email protected]> Thu, 5 Nov 2020 18:30:15 +1000
| Newsgroups | gmane.comp.python.wxpython |
|---|---|
| Message-ID | <[email protected]> |
On 5/11/20 3:53 pm, Steve Barnes wrote: > > You could possibly consider any of: > > * using a virtual desktop of your maximum size, > * on the first call to Fill_Board using a random number generator to > create a seed that you then re-use on each subsequent call > * using a pseudo-random function that produces consistent results > > The first option will slow down your first draw but will speed up all > refreshes. > Thank you Chris and Steve, I completed the project yesterday, except for a little layout beautification. What I ended up doing was create a grid of randomly coloured squares in memory. Operations on this grid then triggers an OnPaint() event to display the grid, as has been suggested. -- Regards, Phil -- You received this message because you are subscribed to the Google Groups "wxPython-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/wxpython-users/750b2078-70c2-1a06-c8be-89ea706924a0%40gmail.com.