mdr/scalariform — Issue #41: Feature request: indentation of multiple class/methods arguments
Author: fanf
Created: 2011-12-23 11:55:52+00:00
State: open

At work, we use the following syntax for multi-line class/methods parameter.

```scala
class SomeClassName(
param1 : Type1
, aLongerParamName: AnOtherType
, param2 : T3
)
```

Main indentation rules are:

* the first parameter is double indented
* comma goes at the start of the line, simply indented
* there is a space after the comma so that all parameters start at the same place
* all ":" are vertically aligned
* the longer parameter name does not have a space before its ';'
* there is a space after the ':'

The last two rules are more likelly more general rules about ':'.

A support for automatic indentation like that would be great !

note: the syntax seems to be borrowed from Javascript and/or Haskel.