iTunes: Keyboard Maestro macros for selecting music library and showing all artists

Posted by Pierre Igot in: iTunes
June 8th, 2010 • 6:33 pm

Over the years, I have developed certain habits when it comes to using iTunes to manage my music library (which is my primary use for iTunes).

Ever since Apple added more view options, I have been using a column-based set-up, i.e. with the Column Browser visible on the left next to the sidebar, with two columns (“Artists” and “Albums”), and the list of tracks on the right:

iTunes set-up

Yet even with this particular set-up, there are still a couple of aspects that I find rather frustrating. One of them is that my list of artists can get very long. (At last count, I have nearly 10,000 of them in my library.) This means that there is often a lot of scrolling up and down the “Artists” column, especially when I want to stop looking at a particular artist or group of artists and go back to displaying all artists.

This involves scrolling all the way back up to the top of the “Artists” column and selecting the “All” option.

As far as I know, iTunes has no shortcut for this simple and really common action (at least in my use of the application). Once the focus is on the “Artists” column, you can use the Home key to scroll back up to the top of the column, but you still have to manually select the “All” item at the top of the list with the mouse.

So today I decided to create a Keyboard Maestro macro for this, and it turns out that it’s pretty simple.

All I had to do was to use the following three actions:

  1. Click Mouse at (300,100) from the Front Window’s Top Left Corner
  2. Type the Home Keystroke
  3. Click Mouse at (300,100) from the Front Window’s Top Left Corner

The first step puts the focus on the “Artists” column. If it so happens that the focus is already on that column, it selects whatever artist happens to be at the top of the visible portion of the list, but that’s not a problem.

The second step scrolls all the way back up to the top of the list, i.e. makes the “All” option at the top of the list visible.

And the third step selects the “All” option.

I called this macro “Show All Artists” and assigned the command-Home shortcut to it, and that was it!

Now, of course, this works with the (300,100) coordinates because that’s the way I have set things up in iTunes for me when viewing the contents of my music library. But even if you have a different set-up, with the Column Browser at the top for example, this macro can easily be adapted to your set-up. It is just a matter of changing the coordinates. The click location is computed relatively to the corners of the front window, so this continues to work as long as you don’t resize your main iTunes window in ways that alter the position of the intended target of the click.

While I was at it, I also created a macro for selecting the main music library. As I pointed out when I wrote about creating an improved “Find” command for iTunes the other day, it is often useful to be able to quickly revert from viewing a specific source or playlist to viewing the main music library.

The macro that I created with Keyboard Maestro works like this:

  1. Click Mouse at (72,100) from the Front Window’s Top Left Corner
  2. Type the Home Keystroke
  3. Click Mouse at (72,100) from the Front Window’s Top Left Corner

It’s the same idea as with the other macro above, except that this time the focus is on the iTunes sidebar.

I called the macro “Select Music Library” and I assigned the control-Home shortcut to it, et voilà.

Now I have two easy-to-remember shortcuts for two very common actions in my use of iTunes, namely showing all artists and selecting the music library.

It would probably also be a good idea for me to incorporate the “Select Music Library” macro as a first step in the “Show All Artists” macro, just in case I try to use the latter when something other than the music library is selected in the sidebar.

That can easily be done in Keyboard Maestro, since I just need to add an “Execute a Macro” action as the first step in my “Show All Artists” macro and select the “Select Music Library” macro for that first step.

Similarly, I have now updated my improved “Find” command from last week by incorporating the “Select Music Library” macro as the first step that macro, instead of the individual clicking and scrolling steps that I was using.

The only uncertainty about all this is that I don’t know how well these macros will work when iTunes becomes temporarily unresponsive. With my large music library, this happens quite often on my machine and the prolonged hiccups with the Spinning Beach Ball of Death might end up interfering with the proper execution of Keyboard Maestro’s macros. I guess we’ll just have to see how it goes.

(But I really do wish that Apple would come up with a faster iTunes. It is getting to be really painful to have to deal with the SBBOD all the time.)

Comments are closed.