void () { CodeStyleSettings rootSettings = CodeStyleSettingsManager.getInstance(getProject()).createTemporarySettings(); CommonCodeStyleSettings settings = rootSettings.getCommonSettings(JavaLanguage.INSTANCE); settings.BLANK_LINES_AROUND_FIELD = 0; settings.BLANK_LINES_AROUND_METHOD = 1; settings.BLANK_LINES_AROUND_CLASS = 0; settings.KEEP_BLANK_LINES_BEFORE_RBRACE = 2; settings.KEEP_BLANK_LINES_IN_CODE = 2; settings.KEEP_BLANK_LINES_IN_DECLARATIONS = 2; settings.BRACE_STYLE = CommonCodeStyleSettings.NEXT_LINE; doTest(); }