I searched a bit here, and I am surprised that no one asked this question. Is Visual Studio 2010 VB smart indentation just awfully broken for multi-line statements? Or am I doing / installing something wrong? I set 4 character padding with keep tabs. Entering a multi-line operator in VB with natural returns gives the following (property names changed to protect the innocent).
Public Sub Sub1()
Dim foo As New MyClassA With {.FileName = "test",
.Format = MyEnumForImageFormat.jpg,
.IsReallySpecial = False,
.Name = "testN",
.SourceId = Guid.NewGuid(),
.VariantName = "TestV",
.Width = 800,
.Height = 600}
End Sub
How can someone format their code this way? I thought maybe I need to reformat (Ctrl + K Ctrl + D):
Public Sub Sub1()
Dim foo As New ImageBase With {.FileName = "test",
.Format = MyEnumForImageFormat.jpg,
.IsReallySpecial = False,
.Name = "testN",
.SourceId = Guid.NewGuid(),
.VariantName = "TestV",
.Width = 800,
.Height = 600}
End Sub
Reformat. , . , . , :
Public Sub Sub1()
Dim foo As New ImageBase With {.FileName = "test",
.Format = MyEnumForImageFormat.jpg,
.IsReallySpecial = False,
.Name = "testN",
.SourceId = Guid.NewGuid(),
.VariantName = "TestV",
.Width = 800,
.Height = 600}
End Sub
, , ? , , ? , - .
. ?