File->settings->Editor->Code Style->看右边有一个Indents Detection
将Detect and use existing file indents for editing这一些的勾去掉,点击OK保存设置

本文介绍如何在IntelliJ IDEA中调整代码缩进设置,避免自动检测并使用现有文件的缩进,以统一代码风格。
File->settings->Editor->Code Style->看右边有一个Indents Detection
将Detect and use existing file indents for editing这一些的勾去掉,点击OK保存设置


被折叠的 条评论
为什么被折叠?