Sunday, June 15, 2008

Best Programming Font

Programming is one of the most noble ways of "communicating" with your computer, not to say "ordering" the machine to labor for you! Of course, after removing the mouse, the keyboard, and that cheap uncalibrated monitor from the picture; programming is the closest one could get to interacting and potentially messing things up in a computer. I find pleasure in programming, as it requires style, finesse, management, and an artistic vision.

Today, most programmers use IDEs (Integrated Development Environment) to write, manage, and compile their codes. The features provided by an IDE are countless. Most of them now include syntax coloring, and most importantly, code completion, thus making it easy for programmers to focus on their objectives rather than deal with unecessary tasks such as a finding a typo somewhere in the code.

I write my programs on windows and occasionally on Linux. I've had a good experience programming on the Mac using Objective-C as well. I was about to make a full transition to unix platforms, but with the introduction of the .Net framework and the new philosophy of the Microsoft people regarding programming, I decided to stick with windows and I program mostly in C# now using Visual Studio. Microsoft made a colossal improvement in its methodologies and the development tools they now provide are excellent. With the new visual studio series (express, and professional editions), I no longer have to worry about the portability of my C programs. Note that Visual Studio 2008 express versions can be downloaded for free! Thanks Microsoft! Aslo, the Visual Studio 2008 professional edition is also available for free, provided you are affiliated with a university. Check the Dreamspark initiative by Microsoft.

Anyway, the point of this post is the font used in the source code editor. Most (i.e. all) programmers prefer to use mono-spaced fonts. The characters in these fonts all occupy the same space in the editor, and therefore, all formatting, spaces, tabs and stuff like that will align perfectly and nicely in your code. The default font that is used in Visual Studio is Courier New. I've been using it since forever. But I got bored with it. After seeing the excellent default fonts in KDE Develop on Linux and in X-Code, I started looking for a font that would substitute for Courier New... and I found it last week! It was already there, on my system, but for some reason I didn't try it in Visual Studio.

The font is Consolas. It is a monospaced font and I simply find it to be excellent for programming. You can download it here.

In Visual Studio, to change the default font
Got to Tools/Options/Fonts and Colors (located under the Environment node to your left)
Voila!

Here's how the Courier New font looks
while the Consolas font looks like this
By the way, the font size that I use is 10.

Cite as:
Saad, T. "Best Programming Font". Weblog entry from Please Make A Note. http://pleasemakeanote.blogspot.com/2008/06/best-programming-font.html

No comments:

Post a Comment