wxImage

Hideki Takahashi wrote:

Dear wxPython users,

I just started using wxPythonOSX

Which version? I'm guessing something older than 2.5.3.1 since there shouldn't be any image handler related errors any more for supported image file types.

on Panther (OSX 10.3) and got different behavior to the wxImage() function on PyCrust and pythonw.

The difference is that PyCrust has a wx.App object (and has initialized the image handlers if this is an older version of wxPython) and when you do an import from a bare pythonw there isn't one created yet. Try this:

  from wxPython.wx import *
  app = wxPySimpleApp()
  img = wxImage("20.bmp")

or even better <wink> use the new wx package:

  import wx
  app = wx.PySimpleApp()
  img = wx.Image("20.bmp")

ยทยทยท

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!