outlining

Visual Studio C# statement collapsing

雨燕双飞 提交于 2019-11-27 05:54:59
When editing really long code blocks (which should definitely be refactored anyway, but that's beyond the scope of this question), I often long for the ability to collapse statement blocks like one can collapse function blocks. That is to say, it would be great if the minus icon appeared on the code outline for everything enclosed in braces. It seems to appear for functions, classes, regions, namespaces, usings, but not for conditional or iterative blocks. It would be fantastic if I could collapse things like ifs, switches, foreaches, that kind of thing! Googling into that a bit, I discovered

How to permanently disable region-folding in Visual Studio 2008

醉酒当歌 提交于 2019-11-26 23:57:24
问题 Anyone know how to turn off code folding in visual studio 2008? Some of my colleagues love it, but I personally always want to see all the code, and never want code folded out of sight. I'd like a setting that means my copy of Visual Studio never folds #regions or function bodies. 回答1: Edit: I recommend this other answer Go to the Tools->Options menu. Go to Text Editor->C#->Advanced. Uncheck "Enter outlining mode when files open". That will disable all outlining, including regions, for all c#

Visual Studio C# statement collapsing

那年仲夏 提交于 2019-11-26 11:47:20
问题 When editing really long code blocks (which should definitely be refactored anyway, but that\'s beyond the scope of this question), I often long for the ability to collapse statement blocks like one can collapse function blocks. That is to say, it would be great if the minus icon appeared on the code outline for everything enclosed in braces. It seems to appear for functions, classes, regions, namespaces, usings, but not for conditional or iterative blocks. It would be fantastic if I could