Mac OS X Hints

Assign custom icons more quickly

OS X lets you create custom icons for your files and folders, which is not only fun but also useful—you can, for instance, place a custom icon on all of a project’s folders to make them easy to identify at a glance.

You can freely download countless types of icons (see screenshot) from sites such as The Iconfactory and InterfaceLift. Or you can use an icon editor, such as Uncommonplace’s Icon Machine ($25) or Mscape Software’s Iconographer ($15), to create your own.

The problem is that assigning custom icons is rather tedious. First, you have to click on the file with the icon you want and choose File: Get Info (Command-I) in the Finder. Next, you click on the small icon in the Get Info window and copy it (Command-C). Then you click on the destination file, open its Get Info window, and paste the icon (Command-V) into the right spot. That’s a lot of clicks, especially if you’re changing multiple icons.

So here’s a time-saver (for those of you running OS X 10.3.3 or later): don’t use the Get Info window when you’re copying the custom icon. Instead, just select the source item in the Finder and press Command-C to copy the icon. Now select the destination, press Command-I to open the Get Info window, click on the small icon image, and press Command-V to paste.

Indy Icons By using custom icons, such as this set from The Iconfactory, you can give your files and folders a look that makes them easy to spot among the background clutter.

Play to Spotlight’s strengths

Yes, Spotlight can dig out the proverbial needle from a haystack (that is, a file), but it can also find and open applications on your hard drive with just a few keystrokes. Want to launch a somewhat-buried application such as Disk Utility? Press Command-space, type

Disk Uti
, and wait a bit, and you’ll soon see the Disk Utility application at the top of the results list. Click on it, and Disk Utility will open.

Unfortunately, the “wait a bit” portion of the process can get old quickly. If you have a big hard drive, you might wait several seconds, during which time Spotlight bores you by spitting out irrelevant results. That’s where third-party launchers can help. The three best-known programs are Objec-tive Development’s LaunchBar ($20, for home use), Peter Maurer’s Butler ($18), and Blacktree’s Quicksilver (free). These programs all work in a similar manner: you type a keyboard shortcut, enter a few letters of the application or document’s name, and press return to open the highlighted item (or use the mouse to choose it from a list of results). Unlike with Spotlight, these searches happen nearly instantly—they don’t try to maintain a live index of all files and their contents on your hard drive—so there’s no annoying wait.

What these utilities generally don’t do as well is look inside files for bits of data (some of them don’t do this at all). In an ideal world then, you’d use Spotlight to search for information within files, and one of the launcher applications to open files and documents. (Make sure to remap any conflicting keyboard shortcuts—LaunchBar and Spotlight, for example, use the same one.)

No problem. After you’ve picked and downloaded your launch application, open the Spotlight preference pane, choose the Search Results tab, and deselect both the Applications and System Preferences options. Now Spotlight will no longer search for applications or system preference panes. What’s more, you should see better performance when you use Spotlight for other searches.

Pump Up the Volume When you need a little extra volume, QuickTime’s preview player lets you “turn it up to 11.” On the left, you see a clip with the normal volume-control slider. On the right, the same clip is playing with an enhanced volume slider.

Give QuickTime previews a volume boost

You’re probably aware that the Finder can preview QuickTime audio and video files—just click once on a QuickTime clip in column-view mode, and you’ll see the movie appear in the Preview column, complete with QuickTime controller for easy playback.

But what do you do for those times when a video’s audio is too quiet to hear? You could import the clip into iMovie and increase the volume, or reach over and crank up your speakers. But there’s a simpler method: hold down the shift key before clicking on the volume-level icon. When you do, QuickTime gives the volume slider more range than it usually has (see screenshot). (Bonus hint: Command-click on the left-facing arrow at the end of the progress slider to see the video play backward.)

Save time when scrolling

You probably scroll through windows and documents hundreds of times a day and use the scroll bar and scroll arrows much of the time to do it. Here are some tricks to make that easier.

First, if you use the scroll arrows at the bottom of the scroll bars to page through long documents, you can save yourself a mouse click when you want to reverse direction. Scroll bar arrows in OS X are sensitive to mouseover actions if another scroll arrow has already been activated. That means if you click and hold one scroll arrow, you can then move your mouse onto the opposite-direction arrow to immediately reverse. Before OS X, you had to first release the mouse button, move to the opposite arrow, click and hold that arrow, and wait for scrolling to commence again.

The scroll arrows need to appear together for this to be useful—there’s not much point to holding the mouse button down while you move the mouse pointer 10 inches down your screen. OS X does this by default, but the arrows appear only at the bottom of the scroll bar area, which isn’t a lot of help if your pointer is at the top. With just a tiny bit of work in Terminal (/Applications/Utilities), though, you can have the best of both worlds—double scroll arrows at both the bottom and the top of the scroll bar.

Launch Terminal and enter the following command:

defaults write "Apple Global Domain" AppleScrollBarVariant DoubleBoth

Press return to execute the command, and you’ll have enabled double arrows at both ends of the scroll bar. Note that if you’d rather not use Terminal, you can use Marcel Bresink’s freeware program TinkerTool. Any newly launched programs will display two sets of arrows, but you must quit and relaunch any programs that were running for the change to take effect (or you could simply log out and log in).

If you ever tire of this feature, the easiest way to revert is to go to the Appearance preference pane, set the Place Scroll Bars option to At Top And Bottom, and then change the Place Scroll Bars option back to Together.

Unix tip of the month

Watch system activity in real time

Have you ever wanted more detail about what your system is doing? Perhaps your hard drive thrashes or a program crashes every time you run it. Perhaps you’d like to see which files get modified when you change a program’s settings. Although there are no foolproof methods for figuring this stuff out, one option is the Unix command



command reports file system activity in real time—in other words, it creates output as things happen. When launched, it starts filling your Terminal screen with output, unless you reroute the output to a text file. Here’s an example of what might appear:

	08:25:15 getattrlist
	/Applications/ 0.000044 MicrosoftMouse

In the first column, you see the time the system activity occurred. Next, you see the name of the file system command (in this case,

). ( Click here for descriptions of the various commands and scroll down to Section 2.) Then you see the file involved (often this space is blank), followed by the amount of time it took the command to execute (
). Last, you see the name of the process that generated the activity. The two most interesting columns are the file involved and the name of the process. Those two values are what may help you figure out what’s happening on your system.

Here’s how I use

to track down a problem:

1. Open Terminal and type

sudo fs_usage -w > ~/Desktop/usage.txt

You must run

as root; that’s why you need to type
. You’ll be asked for an administrator password before you can proceed. This command redirects the
output to a file, making it easy to search through when you’re done.

2. Perform the activity you’d like to investigate—launch the app that crashes, use your machine until you hear the disk churn, and so on.

3. After you’ve observed the behavior you were looking for, switch back to Terminal and press control-C to terminate


4. Switch to your desktop, and use a text editor to open the file usage.txt, which may be somewhat large. If you’re looking for something related to an application, use your text editor’s search feature to find that program’s name. If you’re trying to find the source of a lot of disk activity, look for a whole bunch of

entries in the output. Then look at the last column to see which program created them. If you want to find a preferences file that a program has modified, search for both the program’s name and .plist .


can help you do detective work. You get a detailed peek inside your system—what you see depends on what you do while the utility monitors your system. Type
man fs_usage
for more details.

[ Senior Editor Rob Griffiths is the author of Mac OS X Power Hound, Panther Edition (O’Reilly, 2004), and runs Mac OS X Hints.]

Subscribe to the Best of Macworld Newsletter