X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/8eca4fef106b8327e2e55636de3f68a511a4c392..68fc5c8025e38b9d827383fbfe7ce509ae331c1f:/wxPython/demo/VListBox.py diff --git a/wxPython/demo/VListBox.py b/wxPython/demo/VListBox.py index 30cec2b5f3..fe2112ea5f 100644 --- a/wxPython/demo/VListBox.py +++ b/wxPython/demo/VListBox.py @@ -14,7 +14,7 @@ class MyVListBox(wx.VListBox): if self.GetSelection() == n: c = wx.SystemSettings.GetColour(wx.SYS_COLOUR_HIGHLIGHTTEXT) else: - c = self.GetForegroundColour()#wx.SystemSettings.GetColour(wx.SYS_COLOUR_HIGHLIGHTTEXT) + c = self.GetForegroundColour() dc.SetFont(self.GetFont()) dc.SetTextForeground(c) dc.DrawLabel(self._getItemText(n), rect, @@ -24,11 +24,9 @@ class MyVListBox(wx.VListBox): # required to draw the n'th item. def OnMeasureItem(self, n): height = 0 - for line in self._getItemText(n).split('\n'): w, h = self.GetTextExtent(line) height += h - return height + 5