X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/b68eef002dcb16d6f97215cd224573c6c52a5ca5..6caa0f5cd18fe9fb39c207d5f31fa5633479a822:/wxPython/samples/doodle/doodle.py diff --git a/wxPython/samples/doodle/doodle.py b/wxPython/samples/doodle/doodle.py index 5c4c641fae..47e01d9e6d 100644 --- a/wxPython/samples/doodle/doodle.py +++ b/wxPython/samples/doodle/doodle.py @@ -71,7 +71,7 @@ class DoodleWindow(wx.Window): def InitBuffer(self): """Initialize the bitmap used for buffering the display.""" size = self.GetClientSize() - self.buffer = wx.EmptyBitmap(size.width, size.height) + self.buffer = wx.EmptyBitmap(max(1,size.width), max(1,size.height)) dc = wx.BufferedDC(None, self.buffer) dc.SetBackground(wx.Brush(self.GetBackgroundColour())) dc.Clear()