dotnet / roslyn

The Roslyn .NET compiler provides C# and Visual Basic languages with rich code analysis APIs.
https://docs.microsoft.com/dotnet/csharp/roslyn-sdk/
MIT License
19.02k stars 4.03k forks source link

Unable to outdent #region (and other preprocessor directives) #37575

Open vsfeedback opened 5 years ago

vsfeedback commented 5 years ago

My team uses a lot of #region directives and many of us, including myself, prefer to have them fully-OUTdented. This is something that ReSharper specifically allows, but I've stopped using ReSharper since moving to Visual Studio 2019. However, VS 2019 is now forcing all of my #region statements to be INdented and it's driving me crazy. Please add a setting that allows us to do this (or even one as fancy as the ReSharper one that allows a number of choices between "indented" and "fully-outdented"...

This issue has been moved from https://developercommunity.visualstudio.com/content/problem/665986/unable-to-outdent-region-and-other-preprocessor-di.html VSTS ticketId: 957069 These are the original issue comments:

Visual Studio Feedback System on 7/29/2019, 11:22 PM (10 hours ago):

We have directed your feedback to the appropriate engineering team for further evaluation. The team will review the feedback and notify you about the next steps.

These are the original issue solutions: (no solutions)

sharwell commented 5 years ago

Related to #2487 Related to #12305 Related to #12306 Mentioned in https://github.com/dotnet/roslyn/pull/37433#discussion_r306530258

sharwell commented 5 years ago

🔗 https://developercommunity.visualstudio.com/content/problem/719205/code-style-region-directive-alignment.html

This feedback further requests the ability to select:

hamarb123 commented 1 year ago

I no longer use #region as a result of this in C# (it still works properly in VB from memory). I would start using them again if I could put them to the left.

Gillissie commented 9 months ago

I'm here to add my support for NOT auto-indenting pre-processor directives. There should be an explicit option to make them all non-indented.