Scripting Environment

The term scripting environment is meant to denote a small class of applications dedicated primarily to letting the user edit and run scripts in some language other than AppleScript, while secondarily providing a way to enter and run AppleScript code.

In the pre-Mac OS X world, a good example of such a program was HyperCard. HyperCard’s main purpose was to allow the user to construct an interface and to associate scripts with the elements of this interface; for example, one could write a script to be run when a button was clicked. These scripts were usually in HyperCard’s own internal scripting language, HyperTalk; but each script had a popup menu allowing it, alternatively, to use other available languages such as AppleScript. This was very handy because it meant you could use HyperTalk for the things HyperTalk was good at (such as driving the HyperCard interface) and AppleScript for the things AppleScript was good at (such as driving other scriptable applications).

A similar program is UserLand Frontier. Frontier also has a much less expensive “little brother,” Radio UserLand; for our purposes the two programs are interchangeable. Frontier is meant to store and run scripts in UserLand’s own scripting language, UserTalk; but a Frontier script can use other available languages, including AppleScript.

(The reason HyperCard and Frontier can “see” and incorporate AppleScript is that these are OSA-savvy applications: they can see and incorporate any OSA language, ...

Get AppleScript: The Definitive Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.