force redraw only through EVT_PAINT event and use wxPaintDC, as described in wx documentation
authorEdouard Tisserant
Thu, 11 Apr 2019 13:41:52 +0200
changeset 2592 1c34bd8c5077
parent 2591 5f685bcd3ad6
child 2593 62c5c3589769
force redraw only through EVT_PAINT event and use wxPaintDC, as described in wx documentation
controls/DebugVariablePanel/DebugVariableTextViewer.py
--- a/controls/DebugVariablePanel/DebugVariableTextViewer.py	Thu Apr 11 11:26:47 2019 +0200
+++ b/controls/DebugVariablePanel/DebugVariableTextViewer.py	Thu Apr 11 13:41:52 2019 +0200
@@ -192,10 +192,11 @@
         """
         Redraw content displayed by Viewer
         """
+
         # Create buffered DC for drawing in panel
         width, height = self.GetSize()
         bitmap = wx.EmptyBitmap(width, height)
-        dc = wx.BufferedDC(wx.ClientDC(self), bitmap)
+        dc = wx.BufferedDC(wx.PaintDC(self), bitmap)
         dc.Clear()
 
         # Get Graphics Context for DC, for anti-aliased and transparent