To me, Visual Studio from Microsoft has always looked like it was planned a certain way and was supposed to be used in only this way. What I mean is that it lacked the support for customization and extensibility. Sure, you could change the colors and add third party applications, but what you had to do to accomplish this suggested that you would rather not do so. With the release of Visual Studio 2010, it looks like Microsoft is trying to contradict me. To find out with what kind of success, just read on.
Contributed by Gabor Bernat Rating: / 4 August 03, 2010
Microsoft Visual Studio is an Integrated Development Environment, and most developers use it when developing anything for the Windows platform. In the spring of 2010, the new edition labeled 2010 was launched. Among many of the improvements, extensibility integration caught my eye. Perhaps now we can have a multitude of extensions, following the successful model of the Firefox browser.
Today I will first get into how well the new extensibility is working, and present a couple of third-party add-ins that will further extend and improve your work with Visual Studio. Before I sum up, I will look into how you can add a new look to your IDE via the themes extensions, and point out a hidden feature of the suite.
The IDE for 2010 has been rewritten using the Windows Presentation Foundation, and the internals has been rewritten using the Managed Extensibility Framework. This latter framework is the key to the new extensibility traits. MEF offers a standard way for any application to expose its functions to the extensions, and to consume them as well. Install and start Visual Studio 2010, and under the Tools menus, besides the Add-in Manager, you will find the Extensions Manager too (highlighted in the screen shot below).
This will bring up a new window with the manager; if you're using it for the first time, you will quickly observe the available extensions. The manager works by connecting to the Microsoft database; therefore, the results are always up to date. You can view all this inside a browser, too -- here at the Visual Studio Gallery. You can sort the query result according to multiple criteria, and you can search by name for functionality.
Furthermore, a tree view categorizes the extensions into the areas it tries to solve. Say you are searching for a template, an ASP.NET control or just modeling tool. Using the tree view on the left of the extension manager, you can quickly find any of those.
I must recognize that the platform is well built. However, the question remains that now, two months after the launch of the studio, what kind of good tools do we have at hand? The platform is useless without some strong items to populate it.
After several hours of going through the gallery, I can say that it has a strong collection of quality add-ins. In this article, I will go through a couple of them that caught my eye. If you are one of those developers that want to see as much code as possible and you use the many shortcuts rarely (because the shortcuts are just so much faster), then you will definitely like the Hide Main Menu extension.
After installing this, the main menu will work in a fashion similar to the way the Internet Explorer 8 menu works. By default, you cannot see it; however, it will pop up if you push down the alt keyboard button (release the Alt key and you are back to the original state):
Power Commands for Visual Studio 2010 offer a couple of useful functionality extensions. For example, it can automatically remove and sort the unused directives in C# documents, clear the output panes, copy the path of a file or open the folder that contains it, email a code snippet, undo close, copy/paste references, reload a project, close all and so forth. It contains those few omissions of the IDE that speed up things when you're working on a large project.
If you view more than one document at the same time and do not have a 22” or larger monitor to pair up with, you may want to use the word wrap style for better visualization. However, once you activate it, you will observe that you lose auto-indent while using it. The Word Wrap with Auto-Indent extension solves this issue.
With Office 2007, Microsoft added a pop up selection. This means that whenever you select a group of characters, a little window will pop up that contains some popular commands you can execute on the text. The VS10x Selection Popup implements this functionality in Visual Studio 2010, too:
If you work with the Microsoft color definitions, you know how non-descriptive those names can be, particularly when you're searching for a specific color. These extensions will add a rectangle with the color sample so you can visualize it better. This one has still some glitches, but the idea is great, and it is a good one to look for.
In addition to these, there are many more; however, I will let you discover them. Whether or not you'll want one of them is based on your coding style and the language in which you work. Make sure you check out the gallery, as it may contain some features/additions that can speed up/improve your coding exponentially.
Besides the extensions, there is are add-ins, too. This is something that has been around ever since .Net arrived. These are probably a lot harder to develop and a little more limited, as there were a lot less of them developed. One of them is AtomineerUtiles. This is something every programmer should use. It helps you to comment your code and functions.
Once you install it you can go into the Keyboard section in the options menu and select a shortcut key for the add document function. Once you have done this, push that combination whenever the cursor is in the declaration of a method, and bang! There you have a quick documentation generator. All that is left for you is to fill in the blank spaces. The kind of documentation you want to generate is configurable via the options menu of the add-in.
The following add-ins are not free; however, they are so good that almost every professional programmer uses one of them, so I could not leave them out. The first is for the C# language; it is JetBrains Resharper. In fact, it is so popular that when Microsoft's marketing team decided to use a picture of Visual Studio 2010, they put it on an image on the front page of the IDE.
Presenting all of its features would take way too long. Go to their website to find out about every little detail. However, as a teaser, here are a couple examples. It improves on Intellisense with increased stability; it provides real time syntax checking, and shows the errors/suggestions on the right side of the IDE near the scroll bar.
If you have written some foreach code, with a simple click, you can transform it into lambda and LINQ expressions:
Similar to this, but focusing on the C/C++ language, is Visual Assist X. With both of these pieces of software, you can overwrite the colors used for syntax highlighting. It is possible, for example, to show with bold letters all of the local symbols and such. This leads us to our next section: how do we modify the visual appearance of the Studio?
To start, we have a good extension that revolves around this feature. Visual Studio Color Theme Editor allows users to customize the color palette used for menus, toolbars, tabs, title bars and other environment colors. After installation in the main menu, a new point appears, with a couple of available themes:
The settings here refer only to the IDE itself, and not the code section:
-Aero Theme-
-Expression Theme-
If you want to change how your code looks and perhaps join the "dark side" of the themes for Visual Studio, you can download any of the already-made themes at the Studio Styles Website. Changing between these requires you to go into the Import/Export Settings… menu item and import the settings you will download. Once you start getting bored with Visual Studio, just refresh it with a new look, and you might even feel more motivated after you make the change.
If you push the internal document switch button (Ctrl + Tab) you will see that you can see the name of the documents that are open and cycle through them; however, you cannot see what is inside them. The Visual Studio team implemented here a live preview function via a thumbnail; however, in the late phases of testing some users with low-end notebooks reported performance issues due to this, and the team decided to remove this feature entirely.
Fortunately, we can enable it by running the following command in the run window (Win + R):
With the tools presented here, you can create your own style for Visual Studio and share it with other users. I observed a clear improvement in this section in recent years. Microsoft and the community have slowly begun to offer the tools required for well-made IDE themes customization on the fly. You can even take the Visual Studio frenzy a step further and use the Windows 7 Visual Studio 2010 theme or download one of the many Visual Studio 2010 community wallpapers.
In the hope that you've learned about multiple interesting features to look into for your Visual Studio 2010, I am ending this article. I invite you to express your thoughts about the customization of the new Visual Studio IDE here on the blog, following the article and eventually rate my article. Live With Passion!