瀏覽代碼

Change IDE Kotlin code formatter to follow official recommendations

From https://developer.android.com/kotlin/style-guide

When a function signature does not fit on a single line, break each
parameter declaration onto its own line.Parameters defined in this
format should use a single indent (+4). The closing parenthesis ())
and return type are placed on their own line with no additional
indent.

fun <T> Iterable<T>.joinToString(
    separator: CharSequence = ", ",
    prefix: CharSequence = "",
    postfix: CharSequence = ""
): String {
    // …
}

Signed-off-by: Chris Narkiewicz <hello@ezaquarii.com>
Chris Narkiewicz 4 年之前
父節點
當前提交
9613502253
共有 1 個文件被更改,包括 1 次插入3 次删除
  1. 1 3
      .idea/codeStyles/Project.xml

+ 1 - 3
.idea/codeStyles/Project.xml

@@ -61,6 +61,7 @@
       </option>
       </option>
       <option name="NAME_COUNT_TO_USE_STAR_IMPORT" value="2147483647" />
       <option name="NAME_COUNT_TO_USE_STAR_IMPORT" value="2147483647" />
       <option name="NAME_COUNT_TO_USE_STAR_IMPORT_FOR_MEMBERS" value="2147483647" />
       <option name="NAME_COUNT_TO_USE_STAR_IMPORT_FOR_MEMBERS" value="2147483647" />
+      <option name="CONTINUATION_INDENT_IN_PARAMETER_LISTS" value="false" />
     </JetCodeStyleSettings>
     </JetCodeStyleSettings>
     <MarkdownNavigatorCodeStyleSettings>
     <MarkdownNavigatorCodeStyleSettings>
       <option name="RIGHT_MARGIN" value="120" />
       <option name="RIGHT_MARGIN" value="120" />
@@ -193,8 +194,5 @@
         </rules>
         </rules>
       </arrangement>
       </arrangement>
     </codeStyleSettings>
     </codeStyleSettings>
-    <codeStyleSettings language="kotlin">
-      <option name="ALIGN_MULTILINE_METHOD_BRACKETS" value="true" />
-    </codeStyleSettings>
   </code_scheme>
   </code_scheme>
 </component>
 </component>