Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/301.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python3.5中的wxPydePreactionWarning(模块';wx';没有属性';图像&#GetHandlers';)_Python_Wxpython - Fatal编程技术网

Python3.5中的wxPydePreactionWarning(模块';wx';没有属性';图像&#GetHandlers';)

Python3.5中的wxPydePreactionWarning(模块';wx';没有属性';图像&#GetHandlers';),python,wxpython,Python,Wxpython,将wxPython应用程序从Python 2.5移动到Python 3.5并获得此错误 AttributeError:模块“wx”没有属性“Image\u GetHandlers” 已检查,但该方法的速度中缺少一个词。 你知道任何已知的替代图像处理程序的方法吗 Python代码: handler_types = [handler.Type for handler in wx.Image_GetHandlers()] wx.BITMAP_TYPE_SVG = max(handler_types)

将wxPython应用程序从Python 2.5移动到Python 3.5并获得此错误

AttributeError:模块“wx”没有属性“Image\u GetHandlers”

已检查,但该方法的速度中缺少一个词。 你知道任何已知的替代图像处理程序的方法吗

Python代码:

handler_types = [handler.Type for handler in wx.Image_GetHandlers()]
wx.BITMAP_TYPE_SVG = max(handler_types) + 1
wx.BITMAP_TYPE_SVGZ = wx.BITMAP_TYPE_SVG + 1

该方法的正确名称实际上是
wx.Image.GetHandlers
,带有下划线的版本是从Python没有
staticmethod
时遗留下来的,此后这两个名称都可用

在Phoenix中,静态方法是real
staticmethods
,下划线版本最终被删除。看