AppleScript is in a state of flux and evolution on the new Mac OS X system. AppleScript also faces tremendous competition from the programming tools that come with (and can be installed on) Mac OS X, such as shell scripting tools, Perl, and Java. Nevertheless, this section will describe what you can do with AppleScript and three Mac OS X programs that can be used with AppleScript: Mail, Terminal application (a command-line tool), and TextEdit. Part V begins with a discussion of AppleScript and scripting the new Mac OS X Finder, which is the OS 9 Finder after a major facelift.
This chapter explains some of the familiar Finder-like scripting that you can accomplish on Mac OS X, such as getting information about desktop items (e.g., files, folders, and disks) and making new files. This chapter compares the Mac OS X Finder dictionary to the Mac OS 9 Finder dictionary (and finds few differences, but that is likely to change with new OS X versions).
This chapter describes the use of AppleScript with Apple Computer’s new email application, aptly called “Mail.” This chapter provides descriptions and code examples on setting up a new mail message and getting information about an email account.
Terminal application is the command-line tool or interface (a window or shell that you type script commands into) that comes with Mac OS X. This chapter shows how you can create, compile, and execute AppleScripts from the Terminal program.
It is likely that the TextEdit’s available
AppleScript commands will change with new Mac OS X releases, so this
chapter focuses on TextEdit’s major commands (e.g.,
count, open,
save) and text-related classes, such as
character
, document
,
paragraph
, and text
.