python - Matplotlib Figure Editor with QT4 (Solved) -


i'm building gui using python 2.7, matplotlib version 1.2.1, qt4 4.9.6. goal able load images, rescale them, , perform other small manipulations. since i'm porting gui matlab script made sense use matplotlib, similar commands , whatnot.

since there isn't standard matplotlib traits editor far can tell, i've used this article build editor. works fine in spyder 2.2.0, in eclipse 18-item traceback (last few lines copied here):

file "c:\python27\lib\site-packages\traitsui\qt4\ui_panel.py", line 572, in __init__   layout = self._add_items(content, inner) file "c:\python27\lib\site-packages\traitsui\qt4\ui_panel.py", line 909, in _add_items   self._set_item_size_policy(editor, item, label, stretch) file "c:\python27\lib\site-packages\traitsui\qt4\ui_panel.py", line 1002, in   _set_item_size_policy   is_item_resizable, is_item_springy, stretch) file "c:\python27\lib\site-packages\traitsui\qt4\editor.py", line 388, in set_size_policy   policy.sethorizontalpolicy(qtgui.qsizepolicy.expanding) typeerror: qsizepolicy.sethorizontalpolicy(qsizepolicy.policy): argument 1 has unexpected type 'pyside.qtgui.qsizepolicy.policy' 

in spyder have "qt-python bindings library" set pyside. have idea why there'd conflict in eclipse not in spyder? thanks!

figured out, needed set environmental default (found looking through spyder startup script , checking doing wasn't doing in eclipse):

os.environ.setdefault('qt_api','pyside') 

Comments

Popular posts from this blog

assembly - 8086 TASM: Illegal Indexing Mode -

Java, LWJGL, OpenGL 1.1, decoding BufferedImage to Bytebuffer and binding to OpenGL across classes -

javascript - addthis share facebook and google+ url -