Archive for September, 2008

Dictionary integration with Safari

Saturday, 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

Saturday, 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

Sunday, 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.