Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What's the point of the red underline highlighting in ReSharper 5 for ASP.Net MVC?

I recently upgraded to using ReSharper 5 (currently in beta). I noticed that in ASP.Net MVC projects, ReSharper underlines in red all of the return statements inside a controller:

Annoying Red Underlines

I personally find this pretty annoying because it looks like an error. Clicking on the underlined text doesn't offer any help (ie, a lightbulb). I don't see an option to change the styling of this text in Environment -> Fonts and Colors, and so far it looks like the only way to disable it is to un-check the "Enable ASP.Net MVC References" in the ASP.Net -> Other Re-Sharper options.

What's the point of this highlighting? Am I missing out on something special that ReSharper is offering me? Is there a way to remove the highlighting while still enabling MVC support in ReSharper?

like image 851
Lance McNearney Avatar asked Mar 11 '10 00:03

Lance McNearney


1 Answers

It's not red - it's brown. It matches color of string literals in standard VS color scheme.

To change it's color:

  1. Install ReSharper 6+
  2. Within Visual Studio navigate to ToolsOptionsEnvironmentFonts & Colors
  3. Scroll down to ReSharper ASP.NET MVC * and change the Item foreground color (and Item background if you'd like) to whatever color suits you best. In your specific case you'll want to change the Item foreground of ReSharper ASP.NET MVC View.

If at the third step you can't find the ReSharper items you should reset the Fonts & Colors cache manually by deleting the HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\9.0\FontAndColors\Cache key in the registry (You may have to delete the key located in ...\10.0\..., too.)

like image 67
derigel Avatar answered Sep 28 '22 09:09

derigel