Although EMACS is growing old, filled with passé idiosyncrasies, and rather complicated to tweak, I grew accustomed to it and is now my main editor. I use it for shell scripting, C++, HTML, even. But to use EMACS properly, or a least make it enjoyable a little bit, one must do a fair bit of configuration. Key bindings to match modern keyboards, adding the macros you’re using the most, and, finally, adjusting the color scheme so that your eyes do not bleed after a few hours of work.
But what is a good color scheme?
First of all, many editors start off with, in my opinion, very bad color schemes. White background, black foreground for normal text, then more or less flashy colors for syntax highlighting. Flashy colors on white background are, paradoxically, rather hard to read, especially if you’re not using a very large font. For example, consider this scheme:
I took this from Chabster’s blog. The bright purplish rose is atrocious and most of the colors are not as contrasted as they should be—again, in my own opinion.
White background are, depending on your screen, very luminous and contribute a lot to visual fatigue. Colors that are different but hard to distinguish unless you’re up close, like pale teal and grayish green, are also bad choices for color-coded information—again, no comparative study, just my impressions. However, many do share this view, as you can see from the Joel on Software forum. To alleviate this problem, I use a darker background and avoid using too many colors.
My color scheme originated in the era of CGA color; where you had a quite limited palette of 16 colors. I, of course, adjusted the colors since then, gradually, as technology permitted (do you remember that you needed a plug-in in Visual Studio to have more than those 16 base colors?). I now have a Dark blue background (#000030), moderate grays and white for syntax highlighting, and not that much color for the other elements. Here’s a screen-shot:
I find it rather easy on the eyes, even though I use a small font, the X 6×10 font. But what do you think? What’s your favorite color scheme?
If you want to configure emacs with your own color scheme, you can refer to the Color Theme page from the EMACS wiki. Apparently, I’m not the only one working hard to tweak colors. On Flickr! there’s a emacs screen-shot group that may give you ideas for your own color scheme or layout.