Green Bars in Visual Studio 2010 - visual-studio

I am wondering what these greens things are in Visual Studio 2010. What are they for? They look pretty random but of course they have to have some meaning. Can any one tell me?
At first glance they don't mean any thing to me.
Picture 1:
Picture 2:
Edit:
They show saved changed content during the document open. Once you close the document they disappear.

They show lines that you have changed.
See here for more details and a table showing what the different colours mean:
+-----------+------------------------------+-------------------------+
| Marker | Different from | Different from file |
| colour | file saved on disk? | that was opened? |
+-----------+------------------------------+-------------------------+
| Nothing | No | No |
| Yellow | Yes | Yes |
| Green | No | Yes |
| Orange | Yes | No |
+-----------+------------------------------+-------------------------+
Edit: Blue indicates that the line was changed, saved and then reverted by undoing.
To see the entire list of colour schemes, go to Tools>Opitons>Environment>Fonts and Colors.(or Ctrl+Q.then type "Fonts and Colors")

Yellow - source code that has been changed since you opened the file, and that hasn't been saved.
Green - source code that has been changed since you opened the file, and that has been saved.

IN SUMMARY...
Start out blank.
Make a change = Yellow.
Save the change = Green.
Undo = Orange.
Change the line again = Yellow.

Visual Studio editor margin can also show light blue bars. But it is only substitution of orange color in some dark themes.
In addition to other answers, please note that there is blue instead of orange in dark themes:
Light themes
Dark themes
(orange color is represented as light blue)
Customization
Using Visual Studio Color Theme Editor plugin from the Microsoft, you can focus on the following 3 items:
The same plugin is available also for more recent versions of Visual Studio, for example
Visual Studio 2015 Color Theme Editor.

This is edited lines of text after last save
or/and
Lines of code edited by Edit->Advanced->Format Document. It formats code (spaces, line breaks, etc) corresponding VS settings for current file's language

Those indicate where the source code has been changed.

Related

Settings for the PhpStorm IDE

Does anybody know how can I turn off or change the color to the cursor for the phpstorm IDE?. Please see the image attach.
Thank you so much.
Settings/Preferences | Editor | General
Highlights on Caret Movement section
Disable Highlight matched brace option
P.S.
You can use search box on the top left to quickly find option in Settings/Preferences screen.
If you want to change that color to another one:
Settings/Preferences | Editor | Colors & Fonts| General
Code | Matched brace (that's for v10; in v9 all styles are in single list and not grouped like in v10).

Toggle between layouts in Sublime Text 3

I'm using Sublime Text 3. I have a layout with a screen-height column on the left and three panes on the right (see figure below). This setup is great (especially with the Golden Ratio plugin), but I still miss one feature I had in vim. I had a hotkey that caused the pane that had focus to take up the entire window, like entering full-screen mode for that one file. When done, you could enter the hotkey again to revert to your previous layout. It's as if the original layout of the panes is saved, and the focused pane temporarily takes over the whole window, and when you're done editing the file full-screen, the program remembers how things were laid out and reverts to that. Here's an ASCII-art example:
BEFORE AFTER
---------------------------- ----------------------------
| | | | |
| | | | |
| |-------------| | |
| | | | |
| | | | |
| |-------------| | |
| | | | |
| | | | |
---------------------------- ----------------------------
By typing a hotkey, you switch from BEFORE to AFTER; typing the same hotkey again reverts you to BEFORE, with the same layout and the same tabs in each pane.
Is there a way to do this in Sublime Text 3, including a plugin that might enable this? If the reader knows how to write Sublime plugins, how hard do you imagine writing such a plugin would be? I would guess it wouldn't be too bad: a matter of stashing state somewhere and programatically telling Sublime to revert to that when switching back from full-screen mode.
I know this is a year on, but the MaxPane plugin solves this problem.
https://github.com/jisaacks/MaxPane
Install through package manager, and then use Command Shift Enter to toggle a pane between full screen and within whichever layout you are using.
You may try using Origami, it helps organising layouts, it doesn't have what you want, but it has a Zoom functionality, here's a quote from the author:
Additionally, Origami allows one to zoom the current pane, making it
take up a large portion of the window. As above, first press super+k,
then press:
super+z: Zoom the current pane so it takes up 90% of the screen (the
fraction is changeable in the keybindings) shift+super+z: Unzoom:
equally space all panes (Note: Windows and Linux use ctrl instead of
super.)
There's no way to do what you want currently, though you may try writing a plugin yourself
You could also chose 1, a single panel default switcher: ALT+SHIFT+1-3
https://superuser.com/questions/368785/switch-between-columns-active-tabs-in-sublime-text-2/424987#424987

Change colors of status indicator in Resharper's marker bar

I really like Resharper's marker bar, but I have a form of partial color blindness (deuteranopia), and I'd like to make the green and yellow status indicators more distinguishable. Obviously it's not a big deal since I can inspect the bar for yellow ticks, but if changing it is possible it'd be a nice touch.
With Resharper 7 / Visual Studio 2008: go to Tools > Options > Fonts and Colors. In Display items, scroll to "ReSharper Code Analysis Error Marker on Error Stripe" and update the Item foreground color. The horizontal bars on the Marker Bar will appear as this color for errors.
Same process for warnings and suggestions.
This does not seem to work for Visual Studio 2010, however.
Resharper 7's status bar is much more colorblind friendly, since it uses icons instead of just changing the color of the square.

How to Set the Line Length for VS2010 Automatic line break

I use a wide screen and like to code in 16:9. So sometimes there is a string.Format... or whatever the is larger than the old 4:3 screen format. But VS does not want to use the avaiable space and just always makes a line break at about 50% of the visible line.
Where can I adjust the automatic line break to the wider screen?
btw I am using ReSharper (5.1).
example:
I think this is ReSharper's doing. In ReSharper | Options | Languages | C# | Formatting style | Line Breaks and Wrapping, under Line wrapping there is an entry Right margin (columns) - adjust this upwards to match the width you want ReSharper to wrap to.
I don't believe VS on its own will reflow text.
Note that there is a VS option to display wrapped text (Edit | Advanced | Word Wrap), but as can be seen from the line numbers when this is turned on, that doesn't actually change the text.

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