安装
pip install PyQt5 -i https://pypi.douban.com/simple
pip install PyQt5-tools -i https://pypi.douban.com/simple
通过pycharm配置拓展
settings>Tools>External Tools>+
# QtDesigner配置
Name:QtDesigner #随便起
Description:QtDesigner # 随便起
Program:C:Usersliuwei97AppDataLocalProgramsPythonPython36Libsite-packagesqt5_applicationsQtindesigner.exe # 安装目录
Arguments: 不写
Working directory:$FileDir$ # 路径 mac上用$ProjectFileDir$
# PyUIC配置,用于把ui结尾的文件转换为py结尾的文件
Name: PyUIC # 随便起
Description: PyUIC # 随便起
Program: C:Usersliuwei97AppDataLocalProgramsPythonPython36Scriptspyuic5.exe # 安装目录
Arguments: $FileName$ -o $FileNameWithoutExtension$.py # 生成py文件
Working directory:$FileDir$ # 路径