wxPython question

André andre.roberge at gmail.com
Fri Dec 17 07:54:25 EST 2004


M.E.Farmer wrote:
> Messed up it does need the dots.
> This should handle bmp ico png gif and several other formats.
> Still need to be 32 by 32
>
> wx.InitAllImageHandlers()
> image = wx.Image(file, wx.BITMAP_TYPE_ANY)
> image = image.ConvertToBitmap()
>
> icon = wxEmptyIcon()
> icon.CopyFromBitmap(image)
>
> frame.SetIcon(icon)
>
> Hth,
>  M.E.Farmer

I needed to scale the image down to 16 by 16 on my Windows computer to
make it work.
hth,
André




More information about the Python-list mailing list