from wx.tools.XRCed.xrced import main main()
import os, sys try: from wx.tools.XRCed import xrced except ImportError: from plugins.XRCed import xrced parent_path = os.path.dirname(os.path.dirname(xrced.__file__)) sys.path.append(parent_path) xrced.main()
raise sys.modules['wx.tools.XRCed'] = sys.modules['XRCed'] from wx.tools import pywxrc # The XRCEDPATH environment variable is used to define additional plugin directories xrced_path = os.getenv('XRCEDPATH') this_path = os.path.dirname(__file__) os.environ['XRCEDPATH'] = xrced_path or os.path.join( this_path, "../src/odemis/gui/xmlh") print "'XRCEDPATH' is set to %s" % os.getenv('XRCEDPATH') # Move this to a separate launcher so it can be spread with # odemis def ncf_decorator(ncf): def wrapper(self, node): if (node.firstChild and node.firstChild.nodeType == 3 and node.firstChild.nodeValue.lower().endswith(".png")): # print node.firstChild.nodeValue return True return ncf(self, node) return wrapper pywxrc.XmlResourceCompiler.NodeContainsFilename = ncf_decorator( pywxrc.XmlResourceCompiler.NodeContainsFilename) main()