codealignment
codealignment copied to clipboard
How to align with 4 spaces?
Tabs are evil, you know. But I'd prefer to get this (not tabs, just spaces but more than 1):
SomeMethod(
param1: arg1,
param2: arg2, // 4 spaces.
param3: arg3)
{
// ...
}
instead of this:
SomeMethod(
param1: arg1,
param2: arg2, // 1 space.
param3: arg3)
{
// ...
}
BTW, I'm using this regular expression: :\s*(?<x>[^\s])
.
At the moment code alignment doesn't support this. There's the "add space" option which makes sure there is at least a single space so I guess this could be extended to allow a user specified number of spaces. However, I'm not sure if there's a huge benefit to this and could confuse people what it means.
I'll leave this issue open for now, if you or anyone else can come up with a nice implementation for this I'll accept the pull request.