A fix for broken TextMate arrow keys in Snow Leopard

Update: The latest TextMate update has a fix for this issue. Use the Software Update tab in TextMate’s Preference Pane to get it (you might need to change “Watch For” to “Cutting-Edge” in order to see it). If you’ve already taken the steps below, the new version will still work just fine.

TextMate’s command-left/right arrow key functionality (one of the most commonly used keystrokes) is broken in Mac OS X 10.6 (Snow Leopard).

Fortunately’ there’s a fix. Edit (or create) the file named ~/Library/KeyBindings/DefaultKeyBinding.dict and add the following lines to the end:

"@\UF702" = "moveToBeginningOfLine:"; 
"@\UF703" = "moveToEndOfLine:"; 
"$@\UF702" = "moveToBeginningOfLineAndModifySelection:"; 
"$@\UF703" = "moveToEndOfLineAndModifySelection:";

Quit and re-launch TextMate, and your precious key-combo should be working again. There’s also a Snow Leopard Compability Bundle which does, essentially, the same thing.

Check out this MacroMates bug report for the source of these handy fixes.


Chris

28 August 2009 at 7:50 pm

Couple other here:

http://wiki.macromates.com/Troubleshooting/SnowLeopard

Rick Branson

29 August 2009 at 4:54 pm

Holy crap, thank you so much! I was going to kill myself.

dude

29 August 2009 at 6:43 pm

I assume you can still use ctrl-a and ctrl-e to do the same thing? If so, no need for this :)

Meng

29 August 2009 at 7:20 pm

Yay! You just saved my day man!!

I was just worrying about not being able to do this in TextMate any more and I’ve looked through all the system preferences and got no luck.

Great article!

James

29 August 2009 at 10:26 pm

Looks like the latest Textmate has fixed this and another issue. Just updated to the Cutting Edge version.

Commenting is not available in this weblog entry.