I am getting this exception just after opening up the WIT.
File "c:\python27\lib\site-packages\wx-2.9.2-msw\wx\lib\agw\aui\framemanager.py", line 8544, in OnRender
art.DrawCaption(dc, self._frame, part.pane.caption, part.rect, part.pane)
File "c:\python27\lib\site-packages\wx-2.9.2-msw\wx\lib\agw\aui\dockart.py", line 570, in DrawCaption
self.DrawIcon(dc, rect, pane)
File "c:\python27\lib\site-packages\wx-2.9.2-msw\wx\lib\agw\aui\dockart.py", line 528, in DrawIcon
dc.DrawBitmap(pane.icon, rect.x+2, rect.y+(rect.height-pane.icon.GetHeight())/2, True)
File "c:\python27\lib\site-packages\wx-2.9.2-msw\wx\_gdi.py", line 3770, in DrawBitmap
return _gdi_.DC_DrawBitmap(*args, **kwargs)
TypeError: in method 'DC_DrawBitmap', expected argument 2 of type 'wxBitmap const &'
Python 2.9.2.4 with wx.lib from svn.
Had no problem until today with this, so thought it was me trying out different art providers, but it seems that the following SetIcon call in my code is the cause.
icon = uiutils.GetBitmap('twcb-64.png', True, True)
self.view.SetIcon(icon)
print icon, type(icon)
print self.view, type(self.view)
The two print lines:
<wx._gdi.Icon; proxy of <Swig Object of type 'wxIcon *' at 0x253b0c4> > <class 'wx._gdi.Icon'>
<twcbsrc.views.cellarbook.AppcbView; proxy of <Swig Object of type 'wxFrame *' at 0x4e09940> > <class 'twcbsrc.views.cellarbook.AppcbView'>
If I comment out the SetIcon call then it is working without problem.
Within self.view I have two AuiNotebook which are setup like this:
bookStyle = aui.AUI_NB_DEFAULT_STYLE
bookStyle &= ~(aui.AUI_NB_CLOSE_ON_ACTIVE_TAB)
self._auiBookTop = aui.AuiNotebook(self.topPane, agwStyle=bookStyle,
name='topAuiBook')
# self._auiBookTop.SetArtProvider(tabArt)
Anyone has an idea on this as I am lost.
Werner