python GUI (pycharm + Python3.7.0+PyQt5 配置)

UI需求,搭建开发环境,基于 pycharm + Python3.7.0+PyQt5 。

网上资料众多,深一脚浅一脚过来,多言无益,来吧。

一、武器的准备

1、安装PyQt5:pip install PyQt5

2、安装QtDesigner:

入坑过程:pip install PyQt5-tools ( Could not find a version that satisfies the requirement pyqt5-tools ) -- God.

出坑:安装:qt-opensource-windows-x86-msvc -- 终于有了 Designer.exe.

 

二、配置

1、Pycharm添加QtDesigner,为了生成.ui(Qt界面)文件。

 

Program:指向上述designer.exe的路径
Work directory:使用变量 $FileDir$

2、Pycharm添加PyUIC,将生成的.ui文件转成.py文件。

 

Arguments的值:-m PyQt5.uic.pyuic $FileName$ -o $FileNameWithoutExtension$.py

OK。开始创建UI吧!
---------------------
作者:可乐佳斌
来源:CSDN
原文:https://blog.csdn.net/weixin_41946423/article/details/81236078
版权声明:本文为博主原创文章,转载请附上博文链接!

原文地址:https://www.cnblogs.com/rood/p/10838066.html