Friday, September 9, 2011

How to Set the Font in New Emacs Windows

I frequently use C-5-2 to get a new window without creating a new emacs process. In emacs lingo, each window is called a frame. At some point, I was surprised to find that the new window had a font different than my default font. After some searching, I learned that emacs has a completely separate font specification for new frames. See the GNU Emacs Manual page on Creating Frames. At the bottom of that manual page is where you'll find the recipe:

(add-to-list 'default-frame-alist '(font . "6x13"))
I've used my favorite font name ("6x13") in this example, but that may be too small for many people. Many fonts are available. Try "10x20" for a larger size. Also see the GNU Emacs Manual page on Fonts

No comments:

Post a Comment