本文为个人使用Pycharm时的一些心得,如有错误请指正。
一、Pycharm外观设置
1.1 主题
菜单栏 File --> Settings --> Appearance & Behavior --> Appearance

1、主题:修改上方Theme即可(个人使用Darcula)
2、背景图:修改Background Image,选择路径并调整透明度
1.2 编辑器
1、字体:菜单栏 File --> Settings --> Editor --> Font

调整Font(个人使用Fira Code Medium)
2、编辑风格:菜单栏 File --> Settings --> Editor --> Color Scheme,选择Python

个人使用:(Foreground)
Braces and Operators:#B4B4B4
Built-in name:#569CD6
Class definition:#4EC9B0
Decorator:#FFEBCD
Docstring:#57A64A
Functions:#FFEBCD
Keyword:#569CD6
Keyword argument:#F08080
Line Comment:#57A64A
Number:#DCDCDC
self parameter:#569CD6
Parameter:#F08080
Special Names:#FFEBCD
String:#D69D85
Type annotation:#4EC9B0
个人Scheme链接:https://pan.baidu.com/s/1xYJDA1_Y7bdCGZEiotZpMA
个人Scheme提取码:n7wt
结果图如下:

二、Pycharm使用设置
2.1 虚拟环境
点击右下角Python解释器,选择Add Interpreter

设置Location:文件夹名称即为虚拟环境名称

2.2 Package
点击右下角Python解释器,选择Interpreter Settings

想要安装新的Package可以点击右边Install

1、Manage Repositories
默认源速度较慢,可添加源
豆瓣:https://pypi.douban.com/simple/
清华:https://pypi.tuna.tsinghua.edu.cn/simple/
2、Install Package
上方搜索框搜索Package名称,点击Install Package即可
如:numpy

3、常用Package
科学计算 | Excel处理 | 界面程序 | 网络爬虫 |
---|---|---|---|
datetime | xlrd | pyside2 | requests |
numpy | xlwt | pyqtgraph | bs4 |
pandas | xlutils | lxml | |
scipy | xlsxwriter | ||
matplotlib | openpyxl |