code: def draw_idle(self):
          
          DEBUG_MSG("draw_idle()", 1, self)
          self._isDrawn = False  # Force redraw
          # Create a timer for handling draw_idle requests
          # If there are events pending when the timer is
          # complete, reset the timer and continue.  The
          # alternative approach, binding to wx.EVT_IDLE,
          # doesn't behave as nicely.
          if hasattr(self,'_idletimer'):
              self._idletimer.Restart(IDLE_DELAY)
          else:
              self._idletimer = wx.FutureCall(IDLE_DELAY,self._onDrawIdle)
docs: Delay rendering until the GUI is idle.