File->Setting->Editor->File and Code Templates->python script,右侧框框内输入: # -*- coding:utf-8 -*- ,然后重新启动Pycharm,这样每个新建的Python文件行首都会显示 # -*- coding:utf-8 -*-
Pycharm设置utf-8自动显示
最新推荐文章于 2024-05-24 20:40:41 发布
File->Setting->Editor->File and Code Templates->python script,右侧框框内输入: # -*- coding:utf-8 -*- ,然后重新启动Pycharm,这样每个新建的Python文件行首都会显示 # -*- coding:utf-8 -*-