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$
相关推荐
小灰灰搞电子5 小时前
PyQt QTextBoundaryFinder类详解:精准定位文本边界
pyqt
️学习的小王15 小时前
Anaconda国内镜像配置与conda常用命令
ide·经验分享·python·conda
雾沉川18 小时前
Rust IDE 选型:除 VS Code 之外,RustRover 非商业场景可免费使用
ide·vscode·rust
赵广陆1 天前
企业实战:web服务集成
前端·pycharm·fastapi
小灰灰搞电子1 天前
PyQt 实现自己的桌面萌宠源码分享
pyqt
赵广陆1 天前
企业实战:数据图与状态定义
pycharm·langchain·langgraph
承渊政道2 天前
【Python编程—从入门到实践】(Python列表:从索引到增删排序的系统理解)
开发语言·python·pycharm·索引·列表·增删查改
a-6262 天前
三维重建的步骤-1(采集的是环绕物体均匀旋转一圈的视频)
python·pycharm·三维重建·metashape
2501_915918412 天前
iOS 真机调试工具推荐,安装运行、性能分析有哪些工具
ide·vscode·ios·objective-c·个人开发·swift·敏捷流程
Albert Edison2 天前
PyCharm 字体大小设置
ide·python·pycharm