With the advent of Snow Leopard, it is no longer necessary to use Typinator for simple text replacement patterns. See e.g. the attached screenshot for implementing the arrow shortcuts presented before.

With the advent of Snow Leopard, it is no longer necessary to use Typinator for simple text replacement patterns. See e.g. the attached screenshot for implementing the arrow shortcuts presented before.

I have been using Snow Leopard for a few days now. Unfortunately, my beloved "cycle through application windows" shortcut is not localized anymore (used to be Command for German keyboard layouts). Thanks to this helpful blog post, I was able to recover it, quickly: Simply open System preferences and change the keyboard shortcut for the command "Move focus to next window in application". Hooray!

Let's say you want to customize the look and feel of your Emacs by changing the font. There have been a couple of blog posts comparing monospaced fonts and their aptitude for coding (see, e.g. a nice comparison by Jeff Atwood or the interesting review at Hivelogic). Now, unless you have any other special requirements, it's very easy to change the default font, once you know its correct name. To find the name, fire up Emacs and open the font panel (M-x ns-popup-font-panel). Select the font you would like to use and check out its properties (M-x describe-face). Copy the Family property to your clipboard. Finally, add something like this to your .emacs (replace Espresso_Mono with the family name from the clipboard):
(set-face-attribute 'default nil :family "Espresso_Mono")
That's pretty easy, isn't it? You can customize this even more. Please read the chapter on face customization in the manual. There's also a special chapter on font handling on the Mac in there.
One thing i do use Typinator for, is a shorthand for inserting arrow characters. This is particularly useful when taking notes or creating an outline. I am attaching a screenshot of my shorthand here; for inserting the arrow characters, simply invoke the MacOS X Character Palette.
The shorthand for the downarrow might seem a bit strange (why not use -v?), but this is faster to type and it resembles the LaTeX way of setting a subscript.
If you need more shortcuts for note taking, check out the Typinator sets contained in the TeX To Me bundle by Matthew Taylor!

The recent MacHeist bundle included Typinator. While I haven't used this program, really, I could imagine some of you, my valued readers, are. So, if you want to shun Emacs built-in macro goodness or just want to make all your precious Typinator shorthands/replacements available in Emacs, this simple fix is for you...
... only if you have not enabled Mac specific keyboard shortcuts, i.e. Command is M and Alt/Option is not bound to any Emacs modifier key.
Typinator relies on Command-v to paste the clipboard's contents. This combination clashes with Emacs' default binding (scroll-down). Simply rebind these keys and you are all set:
(global-set-key [(meta v)] 'yank) (global-set-key [(meta y)] 'scroll-down)
If you have recently downloaded a pretest Emacs (e.g. from this fine repository), you'll notice that ns-extended-platform-support (as outlined in the first screencast) is no longer included in the default distribution. So, if you have been relying on the functionality included in this file, you'll have to install it manually. Find all the instructions in the EmacsWiki.

I have been working on a screencast covering AUCTeX and ran into some problems with the built-in preview. The package features some nifty error markers (see screenshot). Alas, the common Mac shortcut for a mouse right-click (by holding the Control key), does not work in Emacs, so you cannot access the error markers' functions correctly without using a "real" mouse. Fortunately, it is rather easy to translate this event:
(global-unset-key [\C-down-mouse-1]) (define-key function-key-map [\C-mouse-1] [mouse-3])
Depending on your preferences and your mouse settings, you might probably want to experiment with this a little. Check out the keybindings using C-h b and search for mouse-2 and mouse-3, and adjust the setting accordingly.
So, please stay put for some AUCTeX screencast madness!
![]()
If you want to quickly create an image of a directory structure, use OmniGraffle's folder import feature: Simply drop the folder whose contents you want to plot on the program's Dock icon, and it will create a visual representation of the folder's contents. An example for this is shown in the last blog entry. This is a good thing™. more
You might have noticed an error popping up in the last screencast, whenever I was opening a php file. This was due to the php-mode package not being installed correctly. Since it is not (yet) included in the basic Emacs distribution, we'd have to install it manually. This is how you do it:
Skip this step if you are using Aquamacs. It has already set up the directory for you (~/Library/Preferences/Aquamacs Emacs).
It's a good idea to have a directory for storing additional packages or customizations separated from the system or application wide central repository. This way, you can install new versions of Emacs and keep your custom packages. A regular Emacs binary build on the Mac will build a "self contained" application, which stores all the Lisp files and additional files required by packages inside the application bundle (/usr/local/share/emacs otherwise). You can check it out by right-clicking on the Emacs icon and selecting "Show package contents"; inside the package you will find a directory Contents/Resources. Now, you could install custom packages into the site-lisp subdirectory there, but if you happened to move your Emacs to the trashcan (only, if you wanted to install a newer version, of course!), you'd also subject these valuable packages to whatever method of waste disposal is implemented on your Mac. To avoid this, it is advisable to have another place to store them. I'd recommend one of the following places:
/Library/Application Support/Emacs or, if you are using other OSes as well, and want to keep your installation of site-wide packages in sync, /usr/local/share/emacs. The first is the usual place for Mac applications to store additional stuff, the second one is conventionally used on GNU/Linux platforms or for non-fink non-MacPorts UNIX applications on the Mac (you'd have to use "Go→Go to Folder" in the Finder to access this directory). I am sure, you'll be able to figure out something by yourself, if you want to keep these kind of directories synchronized across these platforms and a Windows system (store beneath $HOME/Application Data/Emacs?).~/Library/Application Support/Emacs in the Mac-only case, ~/.emacs.d otherwise.If you are opting for /usr/local/share/emacs, you are all set. Skip the to the next section! The following explanations use ~/Library/Application Support/Emacs as an exemplary directory.
There are three relevant subdirectories that are being used by many packages (some of the more sophisticated ones only require the first one): lisp for storing the package functionality, info for storing the package documentation, and etc for storing additional resource files, e.g. images. Either create the subdirectories using the Finder or by firing up Terminal and entering
mkdir -p Library/Application\ Support/Emacs/lisp mkdir -p Library/Application\ Support/Emacs/info mkdir -p Library/Application\ Support/Emacs/etc
This is what the directory structure will look like (seen from your home folder):

Let's tell Emacs that it should consider these directories when searching for libraries! First of all: load-path, the variable used to store information about Lisp installation directories (use C-h v load-path for a description and for displaying its value); add the following lines to your .emacs file (I prefer having these "environment" settings at the top):
;; Adds ~/Library/Application Support/Emacs/lisp and all subdirectories
;; to the variable load-path
(if (fboundp 'normal-top-level-add-subdirs-to-load-path)
(let* ((my-lisp-dir "~/Library/Application Support/Emacs/lisp/")
(default-directory my-lisp-dir))
(setq load-path (cons my-lisp-dir load-path))
(normal-top-level-add-subdirs-to-load-path)))
If your package comes with additional documentation, you'd install the info files in ~/Library/Application Support/Emacs/info. These info files should be referenced from a dir file, so you won't have any trouble accessing them.
(add-to-list 'Info-default-directory-list "~/Library/Application Support/Emacs/info/")
(add-hook 'Info-mode-hook
(lambda ()
(setq Info-additional-directory-list Info-default-directory-list)
))
Open a Terminal, change to the directory where you extracted php-mode and enter
make php-mode.info
You should now see a file called php-mode.info. Copy it to your info directory (~/Library/Application Support/Emacs/info). Download a skeleton dir file here, copy it to the same directory and rename it to dir. If you invoke the Info directory within Emacs now (using C-h i), you should find the PHP mode entry and be able to click on it to access the file's contents.
Now, before you go ahead and install the full-fledged nxthml package, let's start with the simple, most common php-mode there is. Download php-mode.zip from Sourceforge and copy it to ~/Library/Application Support/Emacs/lisp. Add the following lines to your .emacs file:
;; make php-mode available
;; (require 'php-mode)
;; throws an error on my installation, therefore we are using a
;; slightly different mechanism
(autoload 'php-mode "php-mode" "Major mode for editing PHP code." t)
;; associating files having .php extension with php-mode
(add-to-list 'auto-mode-alist '("\\.php\\'" . php-mode))
If you chose /usr/local/share/emacs as your base directory in step 1, copy the file into the site-lisp subdirectory!
Evaluate the lines just entered or restart Emacs. Now, you'll have nice syntax highlighting for php files. Note that mixed HTML/php files do not work reliably using this setup. If you are adventurous, you can try installing nxhtml mode, already. Please refer to the php-mode page in the Emacs Wiki for additional information regarding multiple modes.
Congratulations! You installed your first package and created a nice infrastructure for further additions!
While I haven't made up my mind yet about the West Wing TV series altogether, I really enjoyed John Goodman's appearance as Glen Allen Walken at the beginning of season 5 - 7A WF 83429 (he was acting Speaker of the House and had to step in for Michael Sheen). Best quote: "I'm gonna blow the hell out of something and God only knows what happens next." This is a worthy candidate for the second place on my list of best US Presidents in mainstream post-90s TV shows. Nr. 1 is obviously Powers Boothe acting as (Vice) President Daniels in 24.
Ever since installing a 2x speed CD-ROM drive and a Soundblaster16 into a 486 DX2-66, enqueue staff has been very knowledgeable about all things Multimedia. To support this point, I am including a sound recording of the quote mentioned above.