Yumbrad logo

1.18.10

Emacs / Terminal Misc Fixed font on Mac OS

Filed under: — Bradley @ 5:25 pm

I’ve done this a couple times now, and forgotten what I did, so I’ll blog it this time for me and anyone else. I like the misc-fixed-semicondensed 6×13 font that is the default for xterm in Linux. I eventually got this working well in Mac OS for emacs. Here are the steps:

1. Download and install the MiscFixedSC613 TTF font from http://www.ank.com.ar/fonts/.

2. Add something like the following to your .emacs (this also swaps “command” and “option”, so that meta is next to space, which is how I like it – can still Cmd-V paste from mac clipboard using option key):

(defvar macosx-p  (string-match "darwin" (symbol-name system-type)))
(unless (eq window-system nil)
  (cond (macosx-p
	 (setq default-frame-alist '((width . 110) (height . 89) (top . 22) (left . 0)
				     (background-color . "black")
				     (foreground-color . "#d0e0e9")))
	 (setq mac-option-modifier 'super)
	 (setq mac-command-modifier 'meta)
	 (set-face-font
	  'default "-apple-miscfixedsc613-medium-r-semicondensed--12-100-72-72-m-100-iso10646-1")
	 (setq mac-allow-anti-aliasing nil)))
)

3. Unfortunately, this didn’t really fix anti-aliasing for me – the outlines of my o’s and 8′s were ugly and filled-in, like they’d been flood filled. I also had to do this in terminal:

defaults write org.gnu.Emacs AppleAntiAliasingThreshold 100

Now, everything looked great!

4 Comments »

  1. Hi!
    I love the 6×13 font when coding and downloaded the fonts for use in Xcode, but as You mentioned all o’s got flood filled and that i haven’t been able to solve.
    Any advice would be much appreciated!

    Regards,
    Ulf

    Comment by Ulf — 2.8.10 @ 2:06 pm

  2. Hmmm, Ulf – doing the defaults write thing in terminal fixed my flood filled o’s in emacs. Not sure if it would have other adverse effects, but you could do this do turn off font-anti-aliasing in xcode:

    defaults write com.apple.Xcode AppleAntiAliasingThreshold 100

    If it does more harm than good, you could turn it back on:

    defaults write com.apple.Xcode AppleAntiAliasingThreshold 0

    I’ll try it and comment back (didn’t think to use this font in Xcode, great idea! … haven’t yet integrated emacs as xcode external editor, ala: http://mark.aufflick.com/blog/2004/08/23/sensible-emacs-usage-with-apple-s-xcode)

    Comment by Brad — 2.11.10 @ 1:19 pm

  3. The “defaults write com.apple.Xcode AppleAntiAliasingThreshold 100″ worked for me, not adverse effects yet that I have seen.

    Comment by Brad — 2.11.10 @ 2:55 pm

  4. Regarding the o’s and 8 being filled. Don’t enable font-smoothing when using MiscFixedSC613 font for Mac.

    If you want font smoothing, download and use SECOND link/font on that page. In Mac, it will have the font name – “Fixed”. It looks great on Xcode!

    BTW, thanks for sharing the link to that page. I’ve always like 6×13.fon, but couldn’t find it on Mac even after a long search. Your post made my day! :) )

    Comment by Glendon — 6.28.10 @ 4:41 am

RSS feed for comments on this post.

Leave a comment

Powered by WordPress