On the heels of last issue’s interview with Jonas Salling, author of Salling Clicker, I’m here to reveal some interesting new and often-overlooked AppleScript goodies which happen to include Clicker, a little nugget by Illume Software called iNotify and Kanzu Utilities’ Extra Suites. However, let me first thank our friend Rob Jorgensen from whom I gleaned some of these great tips. In addition, I’d like to note to readers that our first tip, regarding SEC Helper, should be tackled only by moderate-to-advanced users. I don’t recommend beginners go mucking around with OS X package contents.
As you know, Salling Clicker is a very hot ticket these days with its Bluetooth support, robust AppleScript integration and overall cool factor. What you may not know is that a resourceful AppleScripter can put one of Clicker’s internal components to use in a variety of non-Bluetooth/cell phone applications. You see, instead of displaying typical dialog boxes, Salling Clicker provides visual feedback to the user by way of a translucent black bar across the screen with a white text message reversed within that. What I’m about to show you is how you, in your capacity as Clicker Hijacker, can use that same feedback concept in any script you like.
This ‘screen bar’ is generated by a small helper application within Clicker’s preference pane bundle called “SEC Helper” (this acronym is, of course, a hold-over from Clicker’s original name, Sony Ericsson Clicker). This helper app is actually what handles Clicker’s menu bar item and serves as Clicker’s AppleScript terminology dictionary. (See screenshot below)
As such, we can commandeer it for our own uses. (As long as we promise to use its power for good and not evil, of course.) Here’s how to set up SEC Helper to serve as a system-wide AppleScript tool.
- First, we need to extract SEC Helper from its home within the Clicker package. Navigate to ~/Library/PreferencePanes/. In this location, you’ll see “Salling Clicker.prefPane”.
- Next, control-click on Salling Clicker.prefPane and choose ‘Show Package Contents’ from the resulting contextual menu.
Within this, you’ll find various cryptic parts, but what we’re looking for is SEC Helper.
- Just copy SEC Helper out to your desktop. Now that you have SEC Helper isolated, just double-click it. The Salling Clicker phone icon will appear in your menubar and indicates that SEC Helper is running.
Now, check out SEC Helper’s AppleScript dictionary and note the ‘show screen’ command.
- In the screenshot above, you’ll see the ‘show screen’ entry in SEC Helper’s dictionary. We’ll start with a simple ‘show screen’ script. (See below) Note the required ‘message’ parameter whose string dictates what our message actually says.
- In this next illustration, I’ll use the optional ‘duration’ parameter. This means I can add ‘duration 10’ to the end of our ‘show screen message’ command so that Helper is instructed to hold the alert bar for 10 seconds before fading.
- Now, if we run this script, we get this nifty alert bar as a result:
Finally, here’s another interesting example of how this SEC Helper screen message might be used: progress. Sure, it’s not quite as elegant as a true progress bar (see Extra Suites below for that), but it does seem to respond well to fast message changes as one might use in a repeat loop, say, for processing a list of files? This example is fairly useless, but it should give you some great ideas for real-world scripting applications. Also note that the ‘black bar’ is non-intrusive and doesn’t prevent the user from continuing to work while the bar is displayed. Nice.
An additional note on using SEC Helper on its own: If you don’t actually use Salling Clicker with a cell phone, but would like to employ SEC Helper in other capacities as outlined here, you might want it to be truly faceless. This means using SEC Helper without displaying the menubar icon. You can do this with AppleScript, of course:
Once you’ve extracted SEC Helper, you can uninstall the rest of Salling Clicker’s components IF you don’t plan to use them. SEC Helper will work fine independently. However, I recommend you go ahead and pay Salling Clicker’s shareware fee if you use 'Helper for any extended period of time.
For those of you who might be concerned, rest assured that this little secret exposÃ© was written and published with Jonas’ blessing. However, we encourage you to head over to Salling Software and download Salling Clicker whether you’re using it in full or to add SEC Helper to your AppleScript arsenal. Either way, the $10 registration fee is a real bargain.
This little gem offers a very similar benefit to SEC Helper. However, in iNotify’s case, a scripter is given access to an iconic alert element just like that which appears on your Mac’s screen when adjusting the system volume. Better yet, iNotify includes a Photoshop template for creating your own alert boxes and includes one prebuilt for email notifications.
And don’t miss these very 'fabulous desktop widgets. All fully customizable, all AppleScript goodness.
Imagine the possibilities! From the Illume Software website:
Finally, you just can’t beat iNotify’s price: 5 bucks. The complete versatility and limitless possibilities it represents just plain belies this paltry price.
If you’ve ever wanted to use progress bars in your OS X scripts without getting into AppleScript Studio, Extra Suites has your number. In fact, David Lloyd of Kanzu Utilities has created an outstanding background application that kicks up your OS X AppleScript vocabulary to notches unknown to mankind. With system commands like ‘play AIFF’ and ‘multibeep’, string commands like ‘replace’ and ‘sort’ and input commands allowing you to capture keyboard states, Extra Suites can quickly become indespensible. Even those of you who miss the venerable Akua Sweets, which appears to be forever stuck in OS9 Land, will find particular comfort in it.
Plus, Extra Suites is easy to use. It works like a traditional scripting addition by expanding your AS command base, but functions as a faceless background application. Just double-click to launch it and start scripting. Here’s a screenshot of Extra Suites’ progress window in action within a script I wrote to export mail messages from MailSmith into FileMaker Pro.
All this and a whole lot more can be had with Extra Suites for the puny sum of $10. Wow.
Looking back and editing the above-written copy, I realize that I sound like a salesman for each of these little shareware outfits. But let me assure you that I’m not. These are just a handful of really useful goodies which can be had despite today’s tough economic climate. After all, automation is a money-saver in both the fat times and the lean times, right? You can purchase any of these little honeys via the direct purchase and download links below:
- Salling Clicker (contains SEC Helper) - Purchase Link - Direct download link
- iNotify - Purchase Link - Direct download link
- Extra Suites - Purchase Link - Direct download link
In short, I hope this sampling of tool tips and interesting AppleScript discoveries will help you further integrate AppleScript into your daily OS X life. If you have your own little-known AppleScript tools or tips, please send them my way. Email tj @ macscripter.net and I’ll include them in the next AppleScript Toolbox Secrets.