VS 2010 - find text in XAML editor - visual-studio-2010

In VS 2010, when searching for text in the XAML editor, the highlighted text is highlighted in the lightest gray colour when not in focus. Is it possible to change the background colour of the highlighted found item text? I've tried changing the VS theme but cannot find the property which would set this colour. In the screenshot below, the text "Text" is selected but you can barely see it and its driving me mad.

It's a bug that it doesn't show up as the active selection color when you perform a Find. I didn't find a workaround for it until after VS2010 shipped, sorry :( I'll find the Connect bug for you to vote up and then update this answer.

WORKAROUND:
After clicking CTRL + F, then click on the scroll bar in the XAML to regain focus on the XAML and you'll see the find text in the correct colour!

Related

What's the name of the bar below the Property grid in VS?

I'm using the Visual Studio Color Theme Editor extension to help darken up VS2010, found a nice theme that I like however I've got one big problem with it.
On the Property sheet, at the bottom where it says the name of the property and a sort description this theme I'm using is impossible to read; Black on a dark grey background. Unfortunately, I don't know what this specific segment of the Property window is called to change it.
You can not change the text color with the extension.
To figure that out, copy FFFFFF, select all line in the theme editor configuration pane (with Shift), press Ctrl+V (yes, you can do that, pretty neat !) and hit apply : everything that can be themed will then appear white. The text however, will stay black.
You can hopefully change the background color : It's called ToolWindowBackground. It will affect all tool windows of course. There's no specific item for this window in particular.

How to locate the formatting of a line in the Options/Fonts and Colors dialog?

I am using Resharper 6.x with VS2010. One of the features is that if you double click on a variable, it is highlighted and then other usages of the variable are highlighted, like so:
The background and foreground colors of the highlighted variable are too close to each other and I am trying to change it in the Options/Fonts and Colors dialog. It has a small Sample window (below). I've gone through the entire list of display items and can't find the one matching what I see in the coding window.
So 2 questions:
Which display item should I change to affect the back/fore colors of the highlighted variables?
Is there some tool that that will point me to the display item in question for any piece of code?
P.S. I am using the Ragnarok as my base color theme.
P.P.S. This may have nothing to do with Resharper. I turned it off and the coloring was still there. I guess my original question still stands - how to affect the colors of the highlighted variables.
Visual Studio 2010 Reference Highlighting
As you already presumed: The reference highlighting of current selection is not a ReSharper feature but a VS 2010 feature. So you need to look at VS items in Fonts and Colors dialog.
The right display item is Highlighted Reference.
ReSharper Reference Highlighting
ReSharper's equivalent is Highlight usages in file by pressing Shift+Alt+F11.
Then all read references have light blue background color (related display item in Fonts and Colors dialog is ReSharper Read Usage).
And all write references have rose background color (related display item in Fonts and Colors dialog is ReSharper Write Usage).
But the disadvantage of ReSharper's reference highlighting is that you need to press a shortcut. VS does the highlighting automatically.

vs2010 XAML Find highlight is very fade

As you can see at the following picture when I search for a word with "Find Next" button the highlight on the word I'm searching is very faded and difficult to see.
but when I search it with F3 I can see the highlight better because it's on blue background.
Is there any way to apply the blue background also on "Find Next" button??
Thanks!
I think the setting you're looking for is Tools->Options->Environment->Fonts and Colors->Show Settings for Text Editor->Inactive Selected Text.
I switched mine to the red colour that you see in the screenshot below as a test but from your question description you'll want to set Inactive Selected Text to the same value as Selected Text.

What's the vs.net 2010 color item name for highlighted text when searching?

Whenever I do a find/replace in vs.net 2010, I can barely see where the highlighted text is on y screen.
I want to change the background color of the highlighted text during find/replace etc.
In vs.net settings (font and colors), what is the item name that is for the highlighted text during find/replace?
Within Visual Studio 2010
menu: Tools->Options->Environment->Fonts and Colors
in the Selected Items window: choose "Selected Text" (it's the second from the top for me.)
You can then change the background color (on the right side of the dialog window.)
The correct item is inactive selected text.
See Dave's answer here:
visual studio find and replace highlight color
You have to install the Productivity Power Tools extension to change this setting. Then it will be under Find Highlight (Extension).
For me, the selected text setting does not affect the color of highlighting when doing a find/replace or a quick find.
You'll find that one at: Text Editor -> Selected Text. You're looking to set the Item Background property. Be aware, it's the same format used for any time text is selected, not just when find/replace is invoked -- that specific action doesn't have a specific format associated with it.

Highlighted Text background and foreground - How to change?

Here is my scenario. I like my color scheme. I have a dark blue background with light grey text. I have the Plain Text option in VS 2010 in Tools | Options | Environment | Fonts and Colors set to be a dark grey for the foreground and dark blue for the background:
alt text http://www.elbalazo.net/post/vs_plaintext_color.jpg
But I need to fix this major problem/annoyance which is when I highlight some text and then lost focus with my mouse it turns almost completely white!
alt text http://www.elbalazo.net/post/WhiteBackgroundVS2.jpg
And worse, when I mouse over the little section lines of code on the left, the selection of the entire editor goes white with a light grey foreground for text:
alt text http://www.elbalazo.net/post/WhiteBackgoundVS.jpg
Not able to figure out where and how to fix this. I don't see a way. Note: I'm using R# 5.0+ so I don't know if that has anything to do with this color issue or what...maybe it's overriding some VS stuff or this is just a VS issue I don't know..probably just not looking in the right area under Fonts and colors...but a lot of the item foreground elements are read only.
UPDATED:
I think it might be (not sure) this one but I can't test it as the foreground is locked and not editable:
alt text http://www.elbalazo.net/post/vs_brachmatching_color.jpg
I'm pretty sure your first problem can be solved by setting the colors on the 'Highlighted Reference' option in the Fonts and Colors window. If ReSharper is override this setting I couldn't tell you. I don't have it installed on this machine. As for your second problem I have no idea.
If you get too irritated at trying to figure out the color options you could also try Studio Styles for pre-made ones. I believe that is where I got the one I use currently.
I believe the setting you are looking for is "Inactive Selected Text". Found while trying to figure out why my selected search texts were not highlighted in an obvious manner.
Might be a year late... answering for future searches.
ReSharper is indeed overriding some of your settings, but those settings can be found in the same screen, towards the bottom of the listbox.
In Tools | Options | Environment | Fonts and Colors, scroll to the bottom of the 'Display Items:' listbox, and you should see a series of settings that start with ReSharper. For instance, the 'ReSharper Current Line Highlight` was causing me issues when I changed my theme to use a dark background.
Hope that helps.
The highlight for matching references is the "Highlighted Reference" background color (as Sean Copenhaver pointed out).
The highlight for the outlining region hover is "Collapsed Region" (as Brandon Satrom pointed out in his comment on the original question). The foreground color is the color used in the outlining margin and the background color is the color used under the text. You can also disable that highlight by disabling Tools->Options->Environment->General->Enable rich client visual experience, though that will disable other things (animations, gradients, etc.)
The brace matching rectangle is the highlight that appears when you insert or put the caret on a brace (e.g. ")", "]", "}"). It only lets you override the background color because you can't use it to change the foreground (text) color.
I had this same problem (much later) with VS 2010 and R# 7.1.
Disable the "Highlight current line" option in ReSharper > Options > Environment > Editor.
That option, when enabled, causes the VS 2010 color options for Highlighted Reference to not apply.
FWIW I had this problem without ReSharper and in my case tracked it down to the Brace Matching (Rectangle) color setting which looked nothing like what I was seeing in the editor but allowed me to fix the issue anyway.
So this is weird but I was having the same problem and it simply went away when I went to Tools->Options->Environment->Fonts and Colors and changed the font size to 18. I then went back in the same menu and changes it back to 10 (default) and the editor no longer highlights the collapsible regions white. Strange behavior.

Resources