解决windows下Sublime Text 2 运行 PyQt 不显示的方法分享
解决方案
搜了一下,找到一个Linux下的解决方案,如下所示:
SublimeText2运行pySide/pyQt程序的问题 Ctrl-B后,界面不会弹出来,但是后台进程里面有"python.exe",而且使用print能打印出东西来. 解决方法: 打开$sublimeText_dir/Data/Packages/Python/Python.sublime-build 增加"shell":"true",
按图索骥,打开C:\ProgramFiles\SublimeText2目录,没有找到Data目录,也没有Packages目录,猜测应该是放在用户目录下,找找找,在
C:\Users\我的用户名\AppData\Roaming
目录下发现
SublimeText2\Packages\Python
目录,果断编辑Python.sublime-build内容:
{ "cmd":["python","-u","$file"], "file_regex":"^[]*File\"(...*?)\",line([0-9]*)", "selector":"source.python", "shell":"true" }
搞定!