Wednesday, January 16, 2008

Visual Studio .Net Editor Top - Part 2

6. Outlining:

Outlining within the code editor, this is a built-in function of the code editor. It allows you to expand and collapse code regions for things like procedures, classes, etc. So if I want to get just kind of a summary view of all of my code in a particular file I could right click in the code editor and say collapse everything to definitions and what that will do is it will collapse all of your code into just the signature line of it so that you can get more of a summary view of everything that you have in a particular code file.


7. Word Wrap:

Word wrap is kind of cool if you’ve got code that goes too long where you have to scroll off the screen to see the end of your code line. And you can get access to word wrap by pressing control R, control R and what that will do is it will wrap your text around so that you don’t have to do any more horizontal scrolling. Now the only issue with word wrap is that it can make your code look a little bit messy sometimes depending on how you have your code set up, and so word wrap actually works hand in hand with line numbers. So with respect to line numbers you can go ahead and you go to tools options and you can select a checkbox that allows you to see the line numbers of your code as well. This works really well with word warp so that you see where one line ends and the next line begins. Another way to add line numbers to your code is you bring up the macro explorer tool window and there is a macro that’s build in, comes as part of Visual Studio.NET that allows you to turn on and off line numbers very very easily.


8. Line Numbers:

Last but not least you can now do block selection of text within the code editor. So normally if I want to select several lines of text it’s doing it on a line by line basis, but with block selection I could hold alt, the alt key, while I’m dragging my cursor within the code window and it’ll select it as a rectangle rather than selecting it line by line.

What’s another cool way to do selection within the code editor? If I could provide one more little thing that I like to do inside the IDE, it’s very cool, developers, you know, we love to maximize our coding real estate. Visual Studio.NET now supports multi-monitors, so you can have Visual Studio running on one monitor, you can have your application running on another monitor and you can scroll seamlessly between those two. We also have a full screen mode, so I can press shift, alt, enter and it’ll expand Visual Studio into this full screen mode, it gives you more real estate to write your code.

Technorati Tags: ,,,,