System:Windows 10
IDE:PyCharm
一.安装PyQt5
在终端输入以下代码:
pip install PyQt5
二. 安装Qt Designer
pip install pyqt5-tools
三. 配置PyCharm
File --> Settings --> Tools --> External Tools --> “加号”
1. 配置Qt Designer
Name: Qt Designer
Program: PyQt5安装目录中 "designer.exe" 的位置
Working directory: $ProjectFileDir$
2. 配置PyUIC
Name: PyUIC
Program: PyQt5安装目录中 "pyuic5.exe" 的位置
Arguments: $FileName$ -o $FileNameWithoutExtension$.py
Working directory: $ProjectFileDir$