Obscure Finder shortcuts

October 16th, 2008

This is TUAW’s “Tip of the Day” today, and boy has it been useful. Many of my frustrations with Mac OS X and the Finder may have just melted away:

Apparently, you can use Command-Up and Command-Down to navigate through folders.

I’ve been looking for Command-Up since I got my Mac over a year ago.

Somewhat usefully, TUAW’s Mac 101 has a whole section tagged shortcuts.

They also point to the Apple page for shortcuts. I’ve searched and searched for that page in Google and Apple.com and Apple’s help documents - how come I’ve never found it? Human error, I guess.

But there is still something that bothers me. In TUAW’s shortcuts articles they often talk about such-and-such an application being “tremendous value for money” but all it’s doing is filling in a gap in the OS or in documentation standards. As an example, people should not be paying to know what shortcuts an application provides.

Windows UI standards and development tools, and I think more recently the OS itself (though the line for me is blurred slightly through the convenient layer of the Visual Studio .Net IDE) ensure that an application displays its keyboard shortcuts for every command. There are two shortcut types in Windows: The direct command shortcut (e.g. Ctrl-S to save a document) , and the navigational shortcut (e.g. Alt-F for the File menu then X for Exit). They are both labelled in the menus so that if you find a command in the menu, you know what its shortcut is. This is true for contextual menus too.

You can do that in Mac OS X, although it works slightly differently. You press Ctrl-F2 for the menu and then navigate by typing words and using the arrow keys.

But critically, assigning keyboard shortcuts is done very differently in Mac OS X than in Windows and I think that in this case Windows wins. Windows applications manage their own keyboard shortcut assignment (this is bad, and not entirely standardised).

On the other hand, Mac OS X centralises that in the Keyboard control panel preferences pane (this is good), but it doesn’t allow for ambiguity in a hierarchy of menus! That is, if I have three Cut commands in my application’s menus (Edit->Cut, Edit->Sentence->Cut and Edit->Paragraph->Cut) I can’t assign them separate shortcuts! Apple could get around this by allowing “Edit|Cut”, “Edit|Sentence|Cut” and “Edit|Paragraph|Cut” as identifiers, but as far as I can tell they do not.

Furthermore, you have to remember what the menu item you want to assign a shortcut to is called, and type it. That’s right. In a graphical menu-driven UI, you have to TYPE the name of a menu item.

Lastly, but not leastly, how do I pull up a context menu, and why aren’t keyboard shortcuts displayed on that context menu?

Keyboard navigation is one of the major complaints I hear from people switching to Macs, and rightly so. Try as I might, there isn’t a simple solution to some of their problems. The solution to having a right-delete key for example involves installing and configuring a free utility. That’s something that can go wrong, that is inconsistent from one machine to another, and requires redoing when you get a new machine or rebuild.

In short then, I see two major failings in Mac OS X in this arena:

  1. Learning curve: Without keyboard shortcuts on the context menu, how can you learn the shortcuts (see Get Info when you right-click on something in Finder - it should show Command-I)?
  2. Configuration: It’s ambiguous, but more importantly, error prone. It requires copying by typing, in 2008?! Come on Apple.

Temporary look

October 5th, 2008

Apologies for the very half-hearted effort so far on the presentation of this blog.

Someday soon I’ll choose a more advanced theme, or at least tidy this one up a little.

Until then, please just sit back and enjoy the content.

Backspace vs Delete

October 5th, 2008

When computers were still trying to figure out what they were and keyboards were proprietary affairs, different manufacturers did different things for deleting. Many treated the DELETE/DEL/← keys as a left-delete, mimicking the mechanical left-aligned typewriter. A Last-In-First-Out stack of characters. It just fit in with the typing schema. Others had a Backspace key. Yet others had two DEL keys, one left and one right as it became evident that a right-delete was useful too.

It was the wild west of keyboard design… Debates raged. Lives were put on the line. Backspace or Delete? What should it do? What is a cursor? Where should it go?

What a load of crap, Nixta, stop spouting. The short of it is that just as Sinclair, Commodore, Acorn, Atari, Amstrad and Texas Instruments all found themselves writing their own software and building their own hardware, they invented their own keyboard layouts.

By the time the modern PC’s keyboard was reasonably standardised, there was both a Backspace and Delete key (indeed the Apple II had no Delete, just a Backspace). Incidentally, the Backspace key is horribly misnamed. It doesn’t move the cursor back a space as it would on a typewriter, it deletes the character to the left. But never mind.

As a PC user you get very used to the Backspace and Del keys. Even laptops have them both.

Modern Mac laptops do not. They just have a “delete” key, which does what a PC Backspace key does: left-delete.

However, Mac OS X can handle both left and right-deletes. The absence of a dedicated key shouldn’t stop you.

There are two, no, three possible solutions and one nerdly impossible one:

  1. Use an Apple wired keyboard (not a wireless one). This has both left-delete and right-delete keys, just like a 103-key PC keyboard (or I suppose you could just use one of those). That defeats the purpose of a laptop though.
  2. Use fn-delete, the Mac OS shortcut for right-delete.
  3. Install DoubleCommand, a free bit of software that re-assigns certain keys for you. I have it set up to use the ‘\’ key (just below the ‘delete’ key on a Mac Laptop) to behave as right-delete.
  4. Not for mere mortals, or indeed anyone who knows what the outside world is like: Create a keyboard file that redefines your keyboard as you want it.
Below is a sample video of using DoubleCommand. Note that just checking the option to use the ‘\’ key isn’t enough, you have to save it and activate it.


View in High Def

Dictionary integration with Safari

September 27th, 2008

I mentioned in my last post that I would follow up with another neat Safari tick. Here it is: Dictionary Integration.

In actual fact, before people leap down my throat, dictionary integration happens with any Cocoa application. Even TextEdit and TextWrangler. Yes, even XCode, which happily treats word breaks according to Objective-C rules. That is, expectedRaise is treated as two separate dictionary links, “expected” and “Raise”. Neat.

Anyway, how do you get this integration? Control-Command-D will bring up the little dictionary menu window. There are some useful behaviours to this little window:

  • If you keep Control-Command held down, the window will update as you move the mouse around the text.
  • You can use the sub-menu at the bottom-left of the mini-dictionary to choose between the various Dictionary categories (here the word “Dictionary” means the Dictionary Application found at /Applications/Dictionary.app). By default Dictionary, Thesaurus, and Apple (whatever that’s for).
  • You can click the “More…” link at the bottom right of the mini-dictionary to open the Dictionary application at this word.

See the video below for a quick demo. Note the keys pressed throughout at the bottom of the video.

Note: Firefox is not a Cocoa native application and as such does not support this functionality. I frequently come across words I’m unclear about, and so this was a compelling reason to switch from Firefox (of which I’d been an avid proponent for many years) to Safari. On a PC, I will still use Firefox, but on a Mac I’m a Safari man.


Cocoa Dictionary integration from Nixta on Vimeo.

Safari file upload trick

September 27th, 2008

There are a few reasons to use Safari over other browsers on the Mac. Most of them are UI shortcuts based on the fact that Safari is written natively in Cocoa, which gives some direct advantages. I’ll cover another one in a separate video, but this one is a useful shortcut which reminds me of RISC OS’s file load and save operations, back in the day.


Uploading a file with Safari from Nixta on Vimeo.

Navigating with the keyboard

September 21st, 2008

I’ve found that in my line of work I do a lot of typing. I write code for a living, and in my spare time I write a load of old crap.

Tappa tappa tappa. Typety Type. Clickety Clack.

So it became much easier to navigate between and around my computer systems using keyboard shortcuts. On a windows PC, context menus were reachable by keyboard alone. Alt-F would open the File menu. You could use the arrows to navigate the menu structure from there. Ctrl-Space brought up the window’s control menu. Ctrl-E would open explorer. Tab and Alt-Tab and Ctrl-Tab let you navigate through all windows and components of windows.

So, how does Apple fare?

You can set up short-cuts to match any single menu item using System Preferences->Keyboard & Mouse->Keyboard Shortcuts, but that fails already when an application has the same text for multiple submenus. Hopefully, readers will show me how to assign a shortcut to a specific menu tree.

Quicksilver helps tremendously by allowing you to open and act on things quickly, but it doesn’t help within an application.

But here we go. The trick is in the Ctrl-Keys.

Ctrl-F2 will set focus to the menu bar. From there, the arrow keys do what you want, and keys can navigate by spelling.

Ctrl-F8 will set focus to the status bar, but there appear to be two kinds of applications in the status bar - those that register themselves properly (Apple items and MenuMeters, for example), and others (Quicksilver, FreeMem, Evernote, Plaxo Toolbar, etc. etc.). You can’t navigate to the latter!

In a Finder window, pressing Enter opens an item in Windows. In Mac OS X it renames it (like F2 in Windows). Command-O Opens it in Mac OS X.

Windows overall seems slightly more consistent. I’d still like to know how to get a context menu with Mac OS X.