pyqt和pycharm环境搭建

安装

python安装:

https://www.python.org/downloads/release/python-3913/

python3.9.13 64位(记得勾选Path环境变量)

pycharm安装:

https://www.jetbrains.com/pycharm/download/?section=windows

community免费版

换源:

bash 复制代码
pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
pip config set install.trusted-host mirrors.aliyun.com

安装PyQt5和PyQt5-tool

bash 复制代码
python -m pip install --upgrade pip
pip install PyQt5
pip install PyQt5-tools

配置

pycharm中创建QtDesigner,pyuic5,pyrcc5三个外部工具

Qt Designer:和Qt Creator功能一样,设计图形界面并生成.ui文件。

pyuic5:将 .ui 文件转换为 Python 代码,使你可以在 Python 中使用设计好的界面。

pyrcc5:将 .qrc 资源文件转换为 Python 代码,使得你可以在 Python 应用中使用图像、图标等资源。

bash 复制代码
Name:QtDesigner
Group:External Tools
Program:D:\soft\Python\Python39\Lib\site-packages\qt5_applications\Qt\bin\designer.exe
Arguments:$FileDir$\$FileName$ 
Working directory:$FileDir$
bash 复制代码
Name:pyuic5
Group:External Tools
Program:D:\softPython\Python39\Scripts\pyuic5.exe
Arguments:$FileName$ -o $FileNameWithoutExtension$.py
Working directory:$FileDir$
bash 复制代码
Name:pyuic5
Group:External Tools
Program:D:\softPython\Python39\Scripts\pyrcc5.exe
Arguments:$FileName$ -o $FileNameWithoutExtension$.py
Working directory:$FileDir$
相关推荐
寻梦csdn18 小时前
pycharm+miniconda兼容问题
ide·python·pycharm·conda
深蓝海拓20 小时前
PySide6从0开始学习的笔记(二十七) 日志管理
笔记·python·学习·pyqt
电饭叔1 天前
Jupyter学习中的问题--FileNotFoundError
ide·学习·jupyter
noBt1 天前
Windows IDEA 卡顿严重
java·ide·intellij-idea
小疙瘩1 天前
去掉 IDEA 中 mybatis配置文件的局部背景颜色(图解)
java·ide·intellij-idea
zhanglianzhao1 天前
Win 11 WSL 配置Claude code 并在VsCode中使用
ide·vscode·编辑器·claude·cladue code
Keying,,,,1 天前
VScode中终端闪退问题
ide·vscode·编辑器
热爱生活的五柒1 天前
如何在vscode中使用Claude code以及插件中配置setting.json无效的解决方法
ide·vscode·编辑器
JMchen1231 天前
AI编程范式转移:深度解析人机协同编码的实战进阶与未来架构
人工智能·经验分享·python·深度学习·架构·pycharm·ai编程
dzj20211 天前
Visual Studio2022中好用的AI编码工具介绍——Windsurf(Codeium)
ide·ai·visual studio·code