On Fri, 4 Apr 2014 19:31:45 +1100, Shane Stanley <[log in to unmask]> wrote:

>If you're running Mavericks, you can do it in AppleScriptObjC.
<snip some interesting code>

Hmm. Is this maybe a reason to upgrade to Mavericks? I was totally unaware that it had something like this (that wasn't already in Mountain Lion). And it's nice either way that Apple is still making improvements for us high-level-language scripters. (I never learned C because when HyperCard came out, I decided it could handle my needs, then got into AppleScript which opened up apps using shell scripting, then got into Revolution/LiveCode after Hypercard was abandoned).