initial fix for numerous bugs mostly related to to multiline method call parameters...
authorYaroslav Lepenkin <yaroslav.lepenkin@jetbrains.com>
Fri, 5 Jun 2015 10:10:54 +0000 (13:10 +0300)
committerYaroslav Lepenkin <yaroslav.lepenkin@jetbrains.com>
Wed, 2 Sep 2015 09:35:07 +0000 (12:35 +0300)
commit6c3ee1c84b970771bffc203b981918dc58116f3f
tree8eefd00b8c2ef76cf93ffaace584419259648040
parentc841df4760daad4a973be09afde6ff336b9813c2
initial fix for numerous bugs mostly related to to multiline method call parameters. We want to ensure that in sequence: "Parenthesis -> Method Params -> Method Params Children", each member has less indent than it's right sibling.

Currently we check if any param is located on new line, and if so, we enforce children indent. Additionally we check if parenthesis has the same indent as any children, indent is enforced also.

This checks and modifications are performed after formatter's AdjustWhiteSpaceState, when we know all proper whitespaces states,  but before actual modification.
java/java-impl/src/com/intellij/psi/formatter/java/AbstractJavaBlock.java
java/java-tests/testSrc/com/intellij/psi/formatter/java/JavaFormatterMultilineMethodCallParamsTest.java [new file with mode: 0644]
platform/lang-api/src/com/intellij/formatting/Indent.java
platform/lang-api/src/com/intellij/formatting/IndentFactory.java
platform/lang-impl/src/com/intellij/formatting/ExpandableIndent.java [new file with mode: 0644]
platform/lang-impl/src/com/intellij/formatting/FormatProcessor.java
platform/lang-impl/src/com/intellij/formatting/FormatterImpl.java
platform/lang-impl/src/com/intellij/formatting/FormattingStateId.java
platform/lang-impl/src/com/intellij/formatting/IndentInfo.java
platform/lang-impl/src/com/intellij/formatting/InitialInfoBuilder.java
platform/platform-resources-en/src/messages/CodeInsightBundle.properties