Hi,
I have a set of *.ico files that I have img2py'ed into a file called icons, which works great in all places
Except when adding these to a wx.ImageList (called `il` in the following).
See, I would like to replace (for example) the lines:
bmp = wx.Bitmap("settings.ico", type=wx.BITMAP_TYPE_ICO)
il.Add(bmp)
with
bmp = icons.getSettingsBitmap() # the function created by img2py.py
il.Add(bmp)
, assuming that these would basically evaluate to the same: Adding a valid proxy of a C++ wxBitmap instance
to the image list. (printing both versions of bmp gives me something like
<wx._gdi.Bitmap; proxy of C++ wxBitmap instance at _10ab6201_p_wxBitmap>
<wx._gdi.Bitmap; proxy of C++ wxBitmap instance at _48a66201_p_wxBitmap>, which looks fine to me)
However, my attempt fail with the message box:
ยทยทยท
---------------------------
Couldn't add an image to the image list.
---------------------------
OK
---------------------------
Any ideas?
Regards,
--
Vincent Wehren