X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/bf56f4ece08443e35a810916a59775e4e574dc8e..aea9f6d5d3eb8513065583fa8e26d7687c39cc4b:/wxPython/wx/lib/editor/editor.py diff --git a/wxPython/wx/lib/editor/editor.py b/wxPython/wx/lib/editor/editor.py index 943e42dd27..2a3f3af6ba 100644 --- a/wxPython/wx/lib/editor/editor.py +++ b/wxPython/wx/lib/editor/editor.py @@ -241,9 +241,8 @@ class Editor(wx.ScrolledWindow): if not odc: odc = wx.ClientDC(self) - bmp = wx.EmptyBitmap(max(1,self.bw), max(1,self.bh)) - dc = wx.BufferedDC(odc, bmp) - if dc.Ok(): + dc = wx.BufferedDC(odc) + if dc.IsOk(): dc.SetFont(self.font) dc.SetBackgroundMode(wx.SOLID) dc.SetTextBackground(self.bgColor) @@ -942,7 +941,7 @@ class Editor(wx.ScrolledWindow): self.AdjustScrollbars() def OnChar(self, event): - key = event.KeyCode() + key = event.GetKeyCode() filters = [self.AltKey, self.MoveSpecialControlKey, self.ControlKey,