IntelliJ keeps resetting the indent to 4 from 2 on reformat

Answered

On reformat code command IntelliJ indents all my files to 2 even if I set 4 in the settings and even if I imported an Eclipse XML profile with 4 spaces indent. I tried disabling editorconfig and toggling "detect and use existing file indents..." restarting but nothing seems to help.

0
2 comments
Avatar
Permanently deleted user

I guess we can close this as I found the problem. In settings in the "Other Settings" section there is the google-java-format settings which was overriding the settings in the Editor - Code Style section. Pretty confusing.

0

This setting is provided by the third-party plug-in and is not available out of the box: https://plugins.jetbrains.com/plugin/8527-google-java-format .

0

Please sign in to leave a comment.