Default lack of indentation with classes & switch statements

G

Guest

Why does the Visual Studio editor fail to indent cases under switch statements and public/private/protected in class definitions? I've been working with Visual Studio since 4.x and it's always been this way. I thought I'd get used to it, but the failure to indent these lines does nothing but make unreadable and sloppy looking code. I always override this behavior when writing switch statements and defining classes, but I still run into this lack of formatting when viewing auto-generated code and code from others who aren't bugged by this default behavior. Why after all these years hasn't this been corrected or at least made into a formatting option?
 
T

tom_usenet

Why does the Visual Studio editor fail to indent cases under switch statements and public/private/protected in class definitions? I've been working with Visual Studio since 4.x and it's always been this way. I thought I'd get used to it, but the failure to indent these lines does nothing but make unreadable and sloppy looking code. I always override this behavior when writing switch statements and defining classes, but I still run into this lack of formatting when viewing auto-generated code and code from others who aren't bugged by this default behavior. Why after all these years hasn't this been corrected or at least made into a formatting option?

How can you "correct" something that isn't wrong?

The funny thing is that their IDE doesn't let you configure the
indentation style to whatever your in-house style happens to be -
you're stuck with Microsoft's in-house style (which you seem to object
to more than most). Most other decent IDEs have fully configurable
indentation. The single and only indentation style option I can find
in VC.NET is "indent braces".

So you could use another IDE or text editor. Emacs gives you lots of
configurability I believe.

Tom
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top