In every version of Visual Studio up to 2013, code wrapped in #region
s and inactive code in #if
statements are automatically collapsed when you open a C# code file for the first time, when "enter outlining mode when files open" is enabled.
I'm trying to figure out how to enable this in Visual Studio 2015 RC, but even turning on "enter outlining mode when files open" doesn't seem to have any effect. If anything, it seems that the file opens, and then VS activates outlining mode a split second later, without checking to see if anything needs to be collapsed.