# Copyright: (c) 2002 by Total Control Software
# Licence: wxWindows license
#----------------------------------------------------------------------
+# 12/21/2003 - Jeff Grimmett (grimmtooth@softhome.net)
+#
+# o V2.5 compatability update
+#
"""
-img2xpm.py -- convert several image formats to XPM
+img2xpm.py -- convert several image formats to XPM.
Usage:
the -o option.
"""
+import sys
+import wx
+import img2img
-import sys
-import img2img
-from wxPython import wx
-
+app = None
def main():
# some bitmap related things need to have a wxApp initialized...
- if wx.wxGetApp() is None:
- app = wx.wxPySimpleApp()
- img2img.main(sys.argv[1:], wx.wxBITMAP_TYPE_XPM, ".xpm", __doc__)
+ if wx.GetApp() is None:
+ global app
+ app = wx.PySimpleApp()
+ img2img.main(sys.argv[1:], wx.BITMAP_TYPE_XPM, ".xpm", __doc__)
if __name__ == '__main__':