AppleScript Finder Guide English Dialect
Apple Computer, Inc. © 1994 Apple Computer, Inc. All rights reserved. No part of this publication or the software described in it may be reproduced, stored in a retrieval system, or transmitted, in any form or by any means, mechanical, electronic, photocopying, recording, or otherwise, without prior written permission of Apple Computer, Inc. Printed in the United States of America. The Apple logo is a trademark of Apple Computer, Inc.
Contents Tables and Listings Preface vii About This Guide ix Audience ix Organization of This Guide ix For More Information x Getting Started x AppleScript Language x Scripting Additions x Other AppleScript Dialects xi Conventions Used in This Guide xi Chapter 1 Chapter 2 Introduction to Finder Scripting 1 Installation 1 What Is Finder Scripting? 2 Recording Actions in the Finder 5 Modifying Recorded Scripts 6 Simplifying Recorded Scripts 8 Writing Scripts That Control the Finder 10 Finder Objec
The Finder Application Object 18 Properties and Elements of the Finder 20 References to Finder Windows 22 References Returned for the Insertion Location property References Returned for a Point 25 Object Class Definitions 26 Accessory Process 26 Accessory Suitcase 27 Alias File 28 Application 31 Application File 38 Application Process 41 Container 43 Container Window 47 Content Space 50 Control Panel 51 Desk Accessory File 55 Desktop-Object 56 Disk 57 Document File 60 File 61 Folder 63 Font File 65 Font Sui
Chapter 3 Finder Commands 99 Using Command Definitions Syntax 99 Parameters 100 Result 101 Examples 101 Command Definitions 101 Clean Up 104 Close 106 Computer 107 Copy 109 Count 110 Data Size 111 Delete 113 Duplicate 114 Eject 115 Empty 116 Erase 117 Exists 118 Get 119 Make 121 Move 124 Open 125 Print 126 Put Away 127 Quit 129 Restart 130 Reveal 131 Select 132 Set 133 Shut Down 134 Sleep 134 Sort 135 Update 137 99 v
Appendix A Finder Commands at a Glance Commands Placeholders 141 145 Appendix B Finder Errors Index vi 149 147 141
Tables and Listings Chapter 1 Introduction to Finder Scripting Listing 1-1 Listing 1-2 Listing 1-3 Chapter 3 Table 3-2 Appendix A A sample recorded script 6 A script that either takes a snapshot of the current window arrangement or restores a previously stored snapshot 11 A script that adds a new user to the Users & Groups control panel and adds a drop folder for that user to the startup disk 12 Finder Commands Table 3-1 99 Variations from standard behavior in Finder versions of standard application
P R E F A C E About This Guide The AppleScript Finder Guide: English Dialect describes the commands and object classes defined by the Finder for use with the English dialect of the AppleScript language. The Finder scripting software allows you to write, record, or run scripts that control actions in the Finder such as opening and closing folders and manipulating files.
P R E F A C E At the end of the guide are two appendixes and an index. ■ ■ Appendix A, “Finder Commands at a Glance,” summarizes the commands defined by the Finder. Appendix B, “Finder Errors,” lists the error messages returned by the Finder. For More Information 0 Getting Started 0 See the book Getting Started With AppleScript to learn what hardware and software you need to use AppleScript; how to install AppleScript; and how to run, record, and edit scripts.
P R E F A C E Other AppleScript Dialects 0 A dialect is a version of the AppleScript language that resembles a particular human language or a programming language. This guide describes the terms defined by the Finder for use with the AppleScript English dialect. Versions of the Finder for use with other dialects work the same way but define terms and syntax appropriate for those dialects.
C H A P T E R Figure 1-0 Listing 1-0 Table 1-0 1 Introduction to Finder Scripting 1 Finder scripting refers to the use of AppleScript and an application such as the Script Editor to write, record, or run scripts that trigger actions in the Finder. This chapter introduces Finder scripting.
C H A P T E R 1 Introduction to Finder Scripting IMPORTANT Finder scripts that return a lot of information may need as much as several hundred kilobytes (K) of free memory to work correctly. To see how much memory is currently free, activate the Finder, choose About This Macintosh from the Apple menu, and check the number labeled Largest Unused Block in the About This Macintosh window.
C H A P T E R 1 Introduction to Finder Scripting tell application "Finder" copy items of folder "AppleScript" of folder "Projects" of ¬ startup disk to folder "Backups" of disk "Storage" end tell This script consists of a three-line Tell statement that names the Finder application running on the local computer as the target application. (The ¬ symbol is a “soft” return; it tells AppleScript to treat the line it’s on and the line that follows as if they are a single line.
C H A P T E R 1 Introduction to Finder Scripting tell application "Finder" of machine "Macintosh IIci" repeat with i in every disk in desktop if folder "Back Me Up" of i exists then set folderName to name of i & " " & ¬ day of (current date) & " " & time of (current date) set newFolder to make folder at ¬ disk "Storage" with properties {name:folderName} duplicate (items of folder "Back Me Up" of i) to newFolder end if end repeat end tell The Repeat statement in this script applies the statements it conta
C H A P T E R 1 Introduction to Finder Scripting Recording Actions in the Finder 1 You can record almost any actions in the Finder that involve manipulating Finder windows or icons: for example, opening folders, copying files, or changing View settings. To record actions in the Finder, click the Record button in the Script Editor application, then activate the Finder (by clicking on the desktop or choosing Finder from the Applications menu) and perform the actions that you want to record.
C H A P T E R 1 Introduction to Finder Scripting Listing 1-1 A sample recorded script tell application "Finder" activate close every window select startup disk open selection set position of window of startup disk to {4, 43} set size of window of startup disk to {369, 464} select folder "Financial" of startup disk open selection set position of window of folder "Financial" of startup disk to ¬ {378, 43} set size of window of folder "Financial" of startup disk to ¬ {200, 155} select folder "Letters" of
C H A P T E R 1 Introduction to Finder Scripting window, turn on recording, choose the settings you want for each window from the View menu, and turn off recording. Any significant changes you make to the windows’ views will be recorded; however, if some of the View settings for some of the windows are already set the way you want them, the Finder won’t record the action because nothing changes as a result. A more reliable approach is to add lines to the recorded script that set the View settings.
C H A P T E R 1 Introduction to Finder Scripting After you run the new script, the windows have the views specified in the script even if you’ve previously changed them. To modify recorded scripts or create new scripts that control the Finder, you may need to look up the definitions of some of Finder terms. Like any scriptable application, the Finder contains a dictionary of the AppleScript terms that you can use to control the application.
C H A P T E R 1 Introduction to Finder Scripting integers. For the Position property, the two integers specify the coordinates of the upper-left corner of the content region of the window (the portion of the window that displays its contents; the title bar and scroll bars are not part of the content region). For the Size property, the two integers specify the vertical and horizontal dimensions of the window’s content region.
C H A P T E R 1 Introduction to Finder Scripting Writing Scripts That Control the Finder 1 You can use a variety of techniques in scripts you write yourself that you can’t use in recorded scripts. For example, suppose you have several different window arrangements that you like to use, and they tend to evolve and change.
C H A P T E R 1 Introduction to Finder Scripting Listing 1-2 A script that either takes a snapshot of the current window arrangement or restores a previously stored snapshot property boundsAll : {} property refsAll : {} set dialogResult to display dialog ¬ "Restore old snapshot or take new one?" ¬ buttons {"Restore Old Snapshot", "Take New Snapshot"} if button returned of dialogResult is "Restore Old Snapshot" then tell application "Finder" close windows set increment to 0 repeat (number of items in re
C H A P T E R 1 Introduction to Finder Scripting Listing 1-3 shows another script that uses the Display Dialog command. This script automates a couple of tasks that network administrators often have to perform: adding a new user and adding a drop folder for that user.
C H A P T E R 1 Introduction to Finder Scripting Unlike the script in Listing 1-2, the script in Listing 1-3 consists of a single Tell statement, and the Display Dialog command is invoked from within the Tell statement. The dialog box asks for the name of the new user and stores it in the variable newUser. The three statements that follow open the Users & Groups control panel and use the Make command to create a new user object with the name stored in newUser.
C H A P T E R 2 Finder Objects Figure 2-0 Listing 2-0 Table 2-0 2 This chapter begins with a summary of the format used in object class definitions and an introduction to the Finder application object, the outermost container for most other Finder objects. The last section of the chapter provides complete descriptions of the object classes defined by the Finder. Using Object Class Definitions 2 Object class definitions describe what objects that belong to a particular class have in common.
C H A P T E R 2 Finder Objects tell application "Finder" set position of file "MyFile" to {29, 235} end tell The file in this example must be located on the desktop. A file can have only one Position property, distinguished from the other properties of the file by its label, position.
C H A P T E R 2 Finder Objects Commands Handled 2 Objects that belong to the same class can respond to the same commands. Object class definitions list the commands to which all objects of that class respond. For example, the definition for File that begins on page 61 indicates that you can use any of these commands to perform actions on a file: Clean Up, Copy, Count, Data Size, Delete, Duplicate, Exists, Get, Make, Move, Open, Print, Put Away, Reveal, Select, Sort, Update.
C H A P T E R 2 Finder Objects The Finder Application Object The Finder application object belongs to the object class Application. As is usually the case with scriptable applications, the application object functions as the outermost container for most of the objects the Finder defines.
C H A P T E R 2 Finder Objects To obtain a standard reference to an element of the Finder while you’re writing a script, follow these steps: 1. Select the object. 2. Choose Copy from the Edit menu. 3. Activate the Script Editor application. 4. Click at the point in your script where you want to paste the reference. 5. Choose Paste Reference from the Edit menu. Windows are also elements of the Finder application.
C H A P T E R 2 Finder Objects Properties and Elements of the Finder 2 The Finder application, like most other Finder objects, has many properties you can refer to in scripts. Some of these properties provide a shorthand method of referring to certain specialized objects. For example, although the Finder application can contain any number of folders, only one Apple Menu Items folder can be located in the active System Folder for a given Macintosh computer.
C H A P T E R 2 Finder Objects working area of your screen and not contained by a folder, disk, or other object—can be considered elements of either the desktop or of the Finder application object, as shown in the following examples.
C H A P T E R 2 Finder Objects window of startup disk of application "Finder", content space of desktop of application "Finder", desktop of application "Finder", application "Scriptable Text Editor", application "Script Editor"} For complete lists of the Finder application object’s properties and element classes, see the definition for the Application object class, which begins on page 31.
C H A P T E R 2 Finder Objects content space is a special case and the Finder doesn’t consider it a member of class Window (although you can refer to window of desktop in a script). The desktop “window” and the desktop are actually the same object, whereas all other windows are distinct from the objects they belong to and may have different properties. For example, the Position property of a disk is different from the Position property of the disk’s window.
C H A P T E R 2 Finder Objects You can refer to windows by name, by number, or as the window property of the object to which they belong. For example, these statements are equivalent: window "My Folder" window of folder "My Folder" of startup disk These statements are also equivalent: window 1 front window The Finder’s front window isn’t necessarily the active content space, which can be the desktop as well as a window.
C H A P T E R 2 Finder Objects References Returned for a Point 2 To get a reference to the content space that lies under a particular point on the desktop, run a script like this: tell application "Finder" content space {100, 100} end tell --result: window of folder "Projects" of startup disk of application "Finder" The pair of integers in braces identifies the point in which you’re interested relative to the entire screen (including the menu bar), and the result contains a reference either to a window
C H A P T E R 2 Finder Objects Object Class Definitions 2 This section defines the Finder’s object classes. Accessory Process An object of class Accessory Process is a process launched from a desk accessory file. PROPERTIES An accessory process has all the properties defined for object class Process on page 77: Creator Type, File, File Type, Frontmost, Name, Partition Size, Partition Space Used, Remote Events, Scriptable, and Visible.
C H A P T E R 2 Finder Objects DEFAULT VALUE CLASS RETURNED A reference or (if you use the plural form accessory processes) a list of references of the form application "AccessoryProcessName" where AccessoryProcessName is the name of an accessory process as it appears in the Applications menu.
C H A P T E R 2 Finder Objects ELEMENT CLASSES The only elements that an accessory suitcase can contain are objects of class Item (see page 73 for the definition of Item). Items can be identified within an accessory suitcase by name or by number.
C H A P T E R 2 Finder Objects Like any other file, an alias file also has all the properties defined for object class Item on page 73: Bounds, Comment, Container, Content Space, Creation Date, Disk, Folder, Icon, ID, Information Window, Kind, Label Index, Modification Date, Name, Physical Size, Position, Selected, Size, and Window. Unlike other files, an alias file also has this property: original item A reference to the original item associated with the alias file.
C H A P T E R 2 Finder Objects The Get statement in this script returns a list of references to the selected items. The Repeat statement tests the Original Item property for each selected alias file. If the property’s value is a valid reference, the If statement asks the Finder to reveal the original item. For an example of a script application that performs a similar task, see the definition of the Reveal command on page 131.
C H A P T E R 2 Finder Objects Application 2 An object of class Application is the Finder application itself, the outermost container for most Finder objects. Because of its role as the application that controls the Macintosh desktop, the Finder defines its own application object differently from the way most other applications define their application objects.
C H A P T E R 2 Finder Objects extensions folder A reference to the Extensions folder in the System Folder. This folder is used to store extension files. Class: Reference Modifiable: No file sharing A Boolean value that indicates whether file sharing is on (true) or off (false). Class: Boolean Modifiable: Yes fonts folder A reference to the Fonts folder in the System Folder. This folder contains the fonts currently available to the system software.
C H A P T E R 2 Finder Objects product version A string that describes the version of system software running on the same computer as the Finder. Class: String Modifiable: No selection A list of references to the object or objects that are currently selected. The objects in the selection are those that would be cut by a Cut command or copied by a Copy command. If no objects are selected, the value of the Selection property is an empty list.
C H A P T E R 2 Finder Objects temporary items folder A reference to the Temporary Items folder in the System Folder. Applications use this folder to store temporary items. Class: Reference Modifiable: No version A string that describes the version of the Finder Scripting Extension or, for versions of Finder scripting software that don’t require this extension, the version of the Finder file in the active System Folder.
C H A P T E R 2 Finder Objects File (page 61) Folder (page 63) Font File (page 65) Font Suitcase (page 66) Information Window (page 69) Item (page 73) Sharable Container (page 79) Sharing Window (page 85) Sound File (page 88) Suitcase (page 90) Trash-Object (page 91) Window (page 95) Elements of any of these classes can be identified by name or by number.
C H A P T E R 2 Finder Objects This statement identifies a folder: folder ID 918 of startup disk -—result: folder "My Folder" of startup disk of application "Finder" This statement identifies the TeachText application: application file id "ttxt" -—result: file "TeachText 7.
C H A P T E R 2 Finder Objects DEFAULT VALUE CLASS RETURNED Reference. EXAMPLES This script turns on the Calculate Folder Sizes property of the Views control panel: tell application "Finder" set calculate folder sizes of view preferences to true end tell This script turns on file sharing for the local computer. tell application "Finder" set file sharing to true end tell The next example selects all the unselected items in the active window.
C H A P T E R 2 Finder Objects Similarly, the Finder interprets both of these statements as a reference to the Trash: trash trash of desktop Application File 2 An object of class Application File is an application’s file on a disk. References to application files must always include a complete description of the file’s container. Such references are different from standard AppleScript references to application objects, which don’t always require a complete pathname.
C H A P T E R 2 Finder Objects scriptable A Boolean value that indicates whether the application is highlevel event aware (true) or not (false)—that is, whether it can respond to the Open, Run, Print, and Quit commands. Class: Boolean Modifiable: No suggested partition size An integer indicating the amount of memory, in bytes, suggested for running the application.
C H A P T E R 2 Finder Objects tell application "Finder" set x to largest free block set y to partition size of ¬ application file "Scriptable Text Editor" of startup disk if x > y then open application file "Scriptable Text Editor" of startup disk else display dialog ¬ "The Scriptable Text Editor prefers more memory. " & ¬ "To increase free memory, quit one or more applications.
C H A P T E R 2 Finder Objects Minimum Partition size to 460,800 bytes (450K) and at the same time increases the Partition Size to 450K: tell application "Finder" set minimum partition size of ¬ application file "Scriptable Text Editor" of ¬ application "Finder" to 460800 end tell If you then run this script, the Finder sets the Partition Size of the Scriptable Text Editor back to 393,216 bytes (384K) and at the same time decreases the Minimum Partition Size to 384K: tell application "Finder" set partiti
C H A P T E R 2 Finder Objects ELEMENT CLASSES None COMMANDS HANDLED Count, Data Size, Exists, Get, Sort DEFAULT VALUE CLASS RETURNED A reference or, if you use the plural form application processes, a list of references of the form application "ApplicationProcessName" where ApplicationProcessName is the name of an application process as it appears in the Applications menu.
C H A P T E R 2 Finder Objects Container 2 An object of class Container is any Finder container, such as a folder, a disk, or the Trash. PROPERTIES A container has all the properties defined for object class object class Item on page 73: Bounds, Comment, Container, Content Space, Creation Date, Disk, Folder, Icon, ID, Information Window, Kind, Label Index, Modification Date, Name, Physical Size, Position, Selected, Size, and Window.
C H A P T E R 2 Finder Objects expandable A Boolean value that indicates whether the container can be opened within its container in outline view (true) or not (false). Class: Boolean Modifiable: No expanded A Boolean value that indicates whether the item is open in outline view (true) or not (false). Class: Boolean Modifiable: Yes previous list view An integer between 2 and 8 or one of the corresponding constants name, modification date, size, kind, comment, label index, or version.
C H A P T E R 2 Finder Objects ELEMENT CLASSES Objects of these classes can be identified at the top level of a container by name or by number. Page numbers indicate the location of corresponding definitions in this chapter.
C H A P T E R 2 Finder Objects EXAMPLES The first example opens all the containers on the desktop except for the Trash. tell application "Finder" open (containers in desktop whose name is not "Trash") end tell The next example, if saved as a script application, toggles the value of the Completely Expanded property of all containers at the top level of the front window: that is, it alternately expands all the containers and their nested containers or collapses them.
C H A P T E R 2 Finder Objects Container Window 2 An object of class Container Window is a window for a container. For example, the windows for a disk, a folder, or a suitcase are all container windows, while a control panel window, the About This Macintosh window, and an information window are not. PROPERTIES A container window has all the properties defined for object class Window on page 95: Bounds, Closeable, Floating, Index, Modal, Position, Resizable, Titled, Visible, Zoomable, and Zoomed.
C H A P T E R 2 Finder Objects You can’t get or set this property unless the container window is open, and the value of the property isn’t retained after the container window has been closed. Class: Integer Modifiable: No selection A reference to the current selection.
C H A P T E R 2 Finder Objects Font File (page 65) Font Suitcase (page 66) Item (page 73) Sharable Container (page 79) Sound File (page 88) Suitcase (page 90) COMMANDS HANDLED Clean Up, Close, Count, Data Size, Exists, Get, Open, Print, Sort, Update DEFAULT VALUE CLASS RETURNED Reference to a file or, if you use the plural form container windows, a list of references.
C H A P T E R 2 Finder Objects The phrase count of container windows at the beginning of the Repeat loop requests that the Finder count all the container windows. Windows that aren’t container windows, such as information windows, are ignored. The Finder returns an integer, which the Repeat statement uses as the number of times to repeat.
C H A P T E R 2 Finder Objects EXAMPLE This script returns a list of all Finder content spaces that are currently open, including the desktop: tell application "Finder" content spaces end tell --result: {information window of startup disk of application "Finder", window of folder "Projects" of startup disk of application "Finder", window of startup disk of application "Finder", window of disk "Applications" of application "Finder", content space of desktop of application "Finder"} For more information a
C H A P T E R 2 Finder Objects calculate folder sizes A Boolean value that indicates whether the checkbox labeled “Calculate folder sizes” in the Views control panel is selected (true) or not (false). Class: Boolean Modifiable: Yes comment heading A Boolean value that indicates whether the checkbox labeled “Show comments” in the Views control panel is selected (true) or not (false).
C H A P T E R 2 Finder Objects label heading A Boolean value that indicates whether the checkbox labeled “Show label” in the Views control panel is selected (true) or not (false). Class: Boolean Modifiable: Yes size heading A Boolean value that indicates whether the checkbox labeled “Show size” in the Views control panel is selected (true) or not (false).
C H A P T E R 2 Finder Objects ELEMENT CLASSES None COMMANDS HANDLED Clean Up, Close, Copy, Count, Data Size, Delete, Duplicate, Exists, Get, Move, Open, Put Away, Reveal, Select, Sort, Update DEFAULT VALUE CLASS RETURNED Reference to a file or, if you use the plural form control panels, a list of references.
C H A P T E R 2 Finder Objects Desk Accessory File 2 An object of class Desk Accessory File is a desk accessory file on a disk. PROPERTIES A desk accessory file has all the properties defined for object class File on page 61: Creator Type, File Type, Locked, Product Version, Stationery, and Version.
C H A P T E R 2 Finder Objects Desktop-Object 2 An object of class Desktop-Object is the desktop of a computer. The Desktop property of the Finder application is a reference to an object of this class. PROPERTIES A desktop-object has some (but not all) of the properties defined for object class Container on page 43: Container Window, Entire Contents, Previous List View, Selection, and View.
C H A P T E R 2 Finder Objects Folder (page 63) Font File (page 65) Font Suitcase (page 66) Item (page 73) Sharable Container (page 79) Sound File (page 88) Suitcase (page 90) COMMANDS HANDLED Clean Up, Count, Data Size, Exists, Get, Print, Select, Sort, Update DEFAULT VALUE CLASS RETURNED Reference.
C H A P T E R 2 Finder Objects PROPERTIES A disk has all the properties defined for object class Sharable Container on page 79: Exported, Group, Group Privileges, Guest Privileges, Inherited Privileges, Mounted, Owner, Owner Privileges, Protected, Shared, Sharing Window. Like any other sharable container, a disk also has all the properties defined for object class Container on page 43: Completely Expanded, Container Window, Entire Contents, Expandable, Expanded, Previous List View, Selection, and View.
C H A P T E R 2 Finder Objects ELEMENT CLASSES Objects of the classes listed here can be identified at the top level of a disk by name or by number. Page numbers indicate the location of corresponding definitions in this chapter.
C H A P T E R 2 Finder Objects EXAMPLE The script that follows tests the Ejectable property of each item in a list of the mounted disks and ejects every disk that’s ejectable. tell application "Finder" put away (every disk whose ejectable is true) end tell Document File 2 An object of class Document File is a document file on a disk. PROPERTIES A document file has all the properties defined for object class File on page 61: Creator Type, File Type, Locked, Product Version, Stationery, and Version.
C H A P T E R 2 Finder Objects EXAMPLE This script opens all the document files at the top level of a disk: tell application "Finder" open document files in window "My World" end tell Application files, desk accessories, suitcases, and other nondocument files are ignored. File 2 An object of class File can be any file on a disk, including document files, application files, and so on.
C H A P T E R 2 Finder Objects product version The version number shown at the top of the information window for the file. Class: String Modifiable: No stationery A Boolean value that indicates whether the file is a stationery pad (true) or not (false). Class: Boolean Modifiable: Yes version The version number shown near the middle of the information window for the file.
C H A P T E R 2 Finder Objects If you save this script as a script application, it copies a new icon to any files whose icons you drop on the script’s icon.
C H A P T E R 2 Finder Objects ELEMENT CLASSES Objects of these classes can be identified at the top level of the folder by name or by number. Page numbers indicate the location of corresponding definitions in this chapter.
C H A P T E R 2 Finder Objects EXAMPLE This script returns references to all the folders at the top level of the startup disk that have been modified in the last 24 hours: tell application "Finder" folders of startup disk where ¬ modification date > ((current date) - 24 * hours) end tell Font File 2 An object of class Font File is a file that contains font data.
C H A P T E R 2 Finder Objects DEFAULT VALUE CLASS RETURNED A reference to a file or, if you use the plural form font files, a list of references. EXAMPLE If you save this script as a script application, it opens font suitcases or any other containers you drop on its icon and opens the windows for any font files they contain.
C H A P T E R 2 Finder Objects COMMANDS HANDLED Clean Up, Close, Copy, Count, Data Size, Delete, Duplicate, Exists, Get, Move, Open, Put Away, Reveal, Select, Sort, Update DEFAULT VALUE CLASS RETURNED A reference to a suitcase or, if you use the plural form font suitcases, a list of references. EXAMPLE The script that follows moves a font suitcase called Janson Text into or out of the Fonts folder, first asking the user to confirm the move. (If you are using version 1.
C H A P T E R 2 Finder Objects Group 2 An object of class Group is a group file in the Users & Groups control panel window. The Finder can’t recognize or create a group unless the Users & Groups control panel window is open. PROPERTIES bounds The coordinates of the rectangle that bounds the content region of the item’s icon. Class: List of four integers (Bounding Rectangle data type).
C H A P T E R 2 Finder Objects COMMANDS HANDLED Clean Up, Close, Count, Data Size, Exists, Get, Make, Open, Select, Sort, Update DEFAULT VALUE CLASS RETURNED A reference to a group or, if you use the plural form groups, a list of references.
C H A P T E R 2 Finder Objects Unlike other windows, an information window also has these properties: comment The comment displayed in the information window. Class: String Modifiable: Yes creation date The date on which the item to which the information window belongs was created. Class: Date Modifiable: No icon A bitmap of the icon for the item to which the information window belongs.
C H A P T E R 2 Finder Objects partition size An integer indicating the amount of memory, in bytes, that an application is launched with if a block of this size is free (available only for information windows that belong to application files). This value is equivalent to the value in the box labeled “Preferred size” under “Memory Requirements” in the information window (see “Notes”). Class: Integer Modifiable: Yes physical size The physical size of the item on disk, in bytes.
C H A P T E R 2 Finder Objects warn before emptying A Boolean value that indicates whether the Finder should warn the user before emptying the Trash (true) or not (false) (available only for the Trash). Class: String Modifiable: Yes ELEMENT CLASSES None COMMANDS HANDLED Close, Count, Data Size, Exists, Get, Open, Sort DEFAULT VALUE CLASS RETURNED A reference to an information window or, if you use the plural form information windows, a list of references.
C H A P T E R 2 Finder Objects Item 2 An object of class Item is any item in a container. PROPERTIES bounds The coordinates of the rectangle that bounds the content region of the item’s icon. Class: List of four integers (Bounding Rectangle data type). The first two integers specify the coordinates of the upperleft corner of the item’s icon, and the last two integers specify the coordinates of the lower-right corner of the icon.
C H A P T E R 2 Finder Objects The item’s hierarchical file system (HFS) ID number, an integer that identifies an application file, folder, or disk. (For examples of the use of this property, see page 35.) Class: Integer Modifiable: No id information window A reference to the item’s information window. Class: Reference Modifiable: No The kind of item as listed under Kind in the item’s container window.
C H A P T E R 2 Finder Objects size The logical size of the item on disk, in bytes. Class: Integer Modifiable: No window A reference to the window that opens when the item is opened.
C H A P T E R 2 Finder Objects property Extras : false tell application "Finder" if (exists item " Add Extras" of apple menu items folder) ¬ = false and ¬ (exists item " Remove Extras" of apple menu items folder) ¬ = false then make alias file with data (file "Toggle Apple Menu Extras" of ¬ startup disk) at apple menu items folder ¬ with properties {name:" Add Extras"} end if if Extras is false then move contents of folder "Apple Menu Extras" of startup disk to ¬ apple menu items folder set the name of i
C H A P T E R 2 Finder Objects items in the Apple Menu Items folder, and its name changes to Remove Extras after the extra items have been added to that folder. If the value of Extras is false, the first part of the second If statement moves the contents of the Apple Menu Extras folder into the Apple Menu Items folder, changes the name of the alias file to Remove Extras, and sets the value of Extras to true.
C H A P T E R 2 Finder Objects partition size An integer indicating the amount of memory, in bytes, that a process is launched with if a free block of this size exists. This value is equivalent to the value in the box labeled “Preferred size” under “Memory Requirements” in the information window for the application file from which the process was launched, except that the value in the information window is given in kilobytes (K, where 1K = 1024 bytes).
C H A P T E R 2 Finder Objects DEFAULT VALUE CLASS RETURNED A reference or (if you use the plural form processes) a list of references of the form application "ProcessName" where ProcessName is the name of a process as it appears in the Applications menu.
C H A P T E R 2 Finder Objects Unlike other containers, a sharable container also has these properties: exported A Boolean value that indicates whether the sharable container is either shared or inside another container whose contents are being shared. If one of these conditions is true, the value is true and the sharable container can be mounted or accessed remotely; if neither of these conditions is true, the value is false and the container isn’t available to remote computers.
C H A P T E R 2 Finder Objects set to false if you set any of the group, guest, or owner privileges individually. Class: Boolean Modifiable: Yes mounted A Boolean value that indicates whether the sharable container is mounted on another computer’s desktop (true) or not (false). Class: Boolean Modifiable: No owner The name of the sharable container’s owner as indicated in the sharing window for the container.
C H A P T E R 2 Finder Objects ELEMENT CLASSES Objects of these classes can be identified at the top level of a sharable container by name or by number. Page numbers indicate the location of corresponding definitions in this chapter.
C H A P T E R 2 Finder Objects EXAMPLE This script changes the Shared property to false for all sharable containers that belong to a specified owner: tell application "Finder" set shared of sharable containers whose owner is "Greg" to false end tell NOTES The properties Group Privileges, Guest Privileges, and Owner Privileges each return an object of class Sharing Privileges.
C H A P T E R 2 Finder Objects see folders A Boolean value that corresponds to the See Folders checkbox for a specified user or group is selected in a sharable container’s sharing window.
C H A P T E R 2 Finder Objects Sharing Window 2 An object of class Sharing Window is a sharing window that appears when you choose Sharing from the File menu while a sharable container is selected. PROPERTIES A sharing window has all the properties defined for object class Window on page 95: Bounds, Closeable, Floating, Index, Modal, Position, Resizable, Titled, Visible, Zoomable, and Zoomed.
C H A P T E R 2 Finder Objects group privileges The group privileges selected in the sharing window. For example, if the See Folders checkbox is not selected and the See Files and Make Changes checkboxes are selected for a user or group, the value of this property is "See Files, Make Changes" (see page 83 for the definition of Sharing Privileges). Class: Sharing Privileges Modifiable: Yes guest privileges The guest privileges selected in the sharing window (that is, the settings labeled Everybody).
C H A P T E R 2 Finder Objects owner privileges The owner privileges selected in the sharing window. For example, if the See Folders checkbox is not selected and the See Files and Make Changes checkboxes are selected for the container’s owner, the value of this property is "See Files, Make Changes" (see page 83 for the definition of Sharing Privileges). Class: Sharing Privileges Modifiable: Yes protected A Boolean value that indicates whether the sharable container is protected (true) or not (false).
C H A P T E R 2 Finder Objects DEFAULT VALUE CLASS RETURNED A reference to a sharing window or, if you use the plural form sharing windows, a list of references. EXAMPLE This script opens the sharing windows for sharable containers on the desktop that belong to a specified owner: tell application "Finder" open (sharing window of sharable containers whose owner is "John") end tell Sound File 2 An object of class Sound File is a sound file.
C H A P T E R 2 Finder Objects DEFAULT VALUE CLASS RETURNED A reference to a file or, if you use the plural form sound files, a list of references. EXAMPLE This script plays the sound file MySound: tell application "Finder" open file "MySound" of folder "Sounds" of startup disk end tell Status Window 2 An object of class Status Window is a window indicating the progress of an operation in the Finder—for example, the windows that appear when items are being copied or when the Trash is being emptied.
C H A P T E R 2 Finder Objects EXAMPLE If a status window is open, this script returns its name: tell application "Finder" front status window end tell --result: status window "Copy" of application "Finder" Suitcase 2 An object of class Suitcase can be either an accessory suitcase or a font suitcase.
C H A P T E R 2 Finder Objects DEFAULT VALUE CLASS RETURNED Reference to a suitcase or, if you use the plural form suitcases, a list of references.
C H A P T E R 2 Finder Objects Unlike other containers, a trash-object also has these properties: warn before emptying A Boolean value that indicates whether the Warn Before Emptying checkbox in the Trash’s Information Window is selected (true) or not (false). Class: Boolean Modifiable: Yes ELEMENT CLASSES Objects of these classes can be identified at the top level of a trash-object by name or by number. Page numbers indicate the location of corresponding definitions in this chapter.
C H A P T E R 2 Finder Objects EXAMPLE To refer to a trash-object, you must use the Trash property of the desktop: tell application "Finder" clean up trash end tell Note that it’s not necessary to refer to the trash of desktop; the Finder interprets trash as the desktop’s Trash property. User 2 An object of class User is a user file in the Users & Groups control panel window. The Finder can’t recognize or create a user unless the Users & Groups control panel window is open.
C H A P T E R 2 Finder Objects position Two integers that specify the position of the upper-left corner of the user’s icon. Class: List of two integers (Point data type) Modifiable? Yes ELEMENT CLASSES None COMMANDS HANDLED Clean Up, Close, Count, Data Size, Exists, Get, Make, Open, Select, Sort, Update DEFAULT VALUE CLASS RETURNED A reference to a user or, if you use the plural form users, a list of references.
C H A P T E R 2 Finder Objects Window 2 An object of class window is any Finder window. PROPERTIES bounds The rectangle that bounds the content region of the window. (The “window frame”—the title bar and scroll bars—are not part of the content region.) Class: List of four integers (Bounding Rectangle data type). The first two integers specify the coordinates of the upper-left corner of the window, and the last two integers specify the coordinates of the lower-right corner of the window.
C H A P T E R 2 Finder Objects position Two integers that specify the upper-left corner of the content region of the window. (The “window frame”—the title bar and scroll bars—is not part of the content region.) Class: List of two integers (Point data type) Modifiable? Yes resizable A Boolean parameter that indicates whether the window can be resized (true) or not (false). Class: Boolean Modifiable? No titled A Boolean parameter that indicates whether the window has a title bar (true) or not (false).
C H A P T E R 2 Finder Objects COMMANDS HANDLED Clean Up, Close, Count, Data Size, Exists, Get, Open, Print, Sort, Update DEFAULT VALUE CLASS RETURNED Reference. EXAMPLE This script closes all Finder windows. It has the same effect as holding down the Option key and clicking the close box of the front window.
C H A P T E R 3 Finder Commands Figure 3-0 Listing 3-0 Table 3-0 3 This chapter begins with a summary of the format used in command definitions. The rest of the chapter provides complete definitions of the Finder commands. Using Command Definitions 3 Command definitions provide information about what commands do and how to use them in scripts. Each definition contains at least four kinds of information: syntax, parameters, results, and examples.
C H A P T E R 3 Finder Commands For example, here’s the syntax statement for the Move command from page 124: move referenceToObject to referenceToContainer [ replacing ( conflicts | existing items ) ] ¬ To use the Move command, you must replace the placeholders referenceToObject and referenceToContainer with a reference to the object you want to move and a reference to the container to which you want to move it, respectively.
C H A P T E R 3 Finder Commands Result 3 Many (but not all) commands return results. The result of a command is the value generated when the command is executed. The “Result” section of a command definition tells whether a result is returned, and if so, lists its class. For example, the result of a Move command is a reference to the object that was moved. Examples 3 Each command definition includes one or more short examples demonstrating how to use the command.
C H A P T E R 3 Finder Commands Table 3-1 102 Variations from standard behavior in Finder versions of standard application commands (continued) Command Finder version Count Counts elements of a particular class in a container. Behaves like the standard version, except that the Finder always returns a single integer, never a list of integers. Data Size Returns the size, in bytes, of the value returned by a Get command on the same object or objects. Identical to the standard version.
C H A P T E R 3 Finder Commands Table 3-2 lists the commands defined by the Finder Suite—that is, the commands unique to the Finder. Table 3-2 Commands defined by the Finder Suite Command Summary Clean Up Aligns the icons in a window or on the desktop along the grid pattern selected in the Views control panel. Computer Returns information about the local computer’s operating environment. Eject Ejects a disk. Empty Empties the trash. Erase Erases a disk.
C H A P T E R 3 Finder Commands Clean Up 3 A Clean Up command is a request to align objects in a window or on the desktop along the grid pattern selected in the Views control panel. The View property for the window must be 0 (“by Small Icon”) or 1 (“by Icon”). Depending on the parameters used with it, the Clean Up command can have the same effect as choosing Clean Up Window, Clean Up Desktop, or Clean Up All from the Special menu.
C H A P T E R 3 Finder Commands EXAMPLES This script cleans up all of the Finder’s open windows (not including the desktop) for which “by Icon” or “by Small Icon” is selected in the Views menu. The by name parameter specifies that the cleaned up icons are to be arranged in the windows by name.
C H A P T E R 3 Finder Commands However, if the window for a folder is open, you can use a script like this to clean up the contents of the window: tell application "Finder" clean up contents of folder "My Folder" of window of startup disk end tell Close 3 A Close command is a request to close one or more windows.
C H A P T E R 3 Finder Commands EXAMPLES This statement closes all Finder windows: tell application "Finder" to close windows This statement closes all Finder windows whose name includes the word “messages”: tell application "Finder" close windows whose name contains "messages" end You can also specify a container to which a window belongs as the parameter of the Close command: tell application "Finder" close startup disk end tell Computer 3 The Computer command is a request for information about the
C H A P T E R 3 Finder Commands PARAMETERS gestaltSelector The Gestalt selector for the feature you want to test. The Finder converts these constants to the Gestalt codes for the equivalent information about the operating environment: CPU FPU MMU hardware operating system sound system memory available (including virtual memory) memory installed For other selectors, use the appropriate code as described in Inside Macintosh: Operating System Utilities.
C H A P T E R 3 Finder Commands This script returns an integer that indicates the total amount of memory available (including virtual memory), in bytes: tell application "Finder" computer memory available end tell Copy 3 The Copy command is a request to copy an object or objects to a new location. The Finder version is similar to the standard application command described in the AppleScript Language Guide, except that the Finder’s Copy command must include parameters.
C H A P T E R 3 Finder Commands EXAMPLE This script copies two files and places them in a folder on another disk: tell application "Finder" copy {file "Release Notes" of disk "My World", ¬ file "Report" of disk "My World"} to folder "Backups" of ¬ startup disk end tell Count 3 The Count command counts the number of elements of a particular class in a container.
C H A P T E R 3 Finder Commands referenceToContainer A reference to the container whose elements are to be counted. If you do not specify this parameter, the Finder counts the elements in the default target of the Tell statement (for example, the Finder application). Class: Reference Default value: Reference to default target of Tell statement RESULT Integer. EXAMPLES In the following example, every item of window "My World" returns a list of items. The Finder counts the items in the list.
C H A P T E R 3 Finder Commands little meaning for the Finder, because the result of a Get command for most Finder objects is a reference. In the case of icons, Data Size returns the data size of the icon family. SYNTAX data size of referenceToObject [ as className ] PARAMETERS referenceToObject A reference to the object or objects whose data size is to be returned. Class: Reference className The class of data for which to determine the size.
C H A P T E R 3 Finder Commands EXAMPLE This script returns a list of integers that specify the size, in bytes, of the icons for the files My File and My Other File, both located on the startup disk: tell application "Finder" data size of {icon of file "My File" of startup disk, ¬ icon of file "My Other File" of startup disk} end tell --result: {1016, 2320} Delete 3 A Delete command is a request to delete one or more objects.
C H A P T E R 3 Finder Commands EXAMPLE tell application "Finder" delete file "OldFile" of startup disk end tell Duplicate 3 A Duplicate command is a request to make a copy of an object or objects and insert the new copy either at a specified location or in the same container as the object that was copied.
C H A P T E R 3 Finder Commands EXAMPLE This script duplicates a file to a disk, replacing any items at the top level of the disk that have the same name: tell application "Finder" duplicate file "My File" of startup disk ¬ to disk "Backup" replacing conflicts end tell You can use replacing existing items, with replacing, or replacing true instead of replacing conflicts without changing the meaning of the script.
C H A P T E R 3 Finder Commands RESULT A reference to the ejected disk or a list of references. EXAMPLE This script ejects the disk named Untitled: tell application "Finder" to eject disk "Untitled" NOTES If you use the Eject command to eject a disk, the disk’s dimmed icon remains on the desktop after the disk ejects. To eject a disk without retaining its dimmed icon, use the Put Away command, which is defined on page 127. Empty 3 An Empty command is a request to empty the trash.
C H A P T E R 3 Finder Commands RESULT A reference to the trash container that was emptied. EXAMPLE tell application "Finder" to empty the trash Erase 3 The Erase command is a request to erase one or more disks. It is equivalent to selecting one or more disk icons on the desktop and choosing Erase Disk from the Special menu. Before the specified disk is erased, a dialog box appears asking the user to confirm that formatting should proceed.
C H A P T E R 3 Finder Commands Exists 3 An Exists command is a request to determine whether the object specified by a reference exists. The Finder version of the Exists command is identical to the standard version described in the AppleScript Language Guide. SYNTAX exists referenceToObject referenceToObject exists PARAMETER referenceToObject A reference to the object to find or a list of references. Class: Reference or list of references RESULT A Boolean value.
C H A P T E R 3 Finder Commands else display dialog "The Storage cartridge isn’t mounted." end if end tell Note that you can’t use the Move command instead of the Copy and Delete commands in this script, because the Move command changes to Copy when moving items between volumes. Get 3 The standard application command Get is a request to return the value of an object or objects.
C H A P T E R 3 Finder Commands RESULT A reference or list of references to the requested objects or, in the case of properties that consist of a value, a value of either the object’s default value class or the class specified by the className parameter, or a list of values of that class. If the Finder can’t return data in the value class specified by the className parameter, it generates an error.
C H A P T E R 3 Finder Commands NOTES The word get in the Get command is optional. For example, these statements are equivalent: name of startup disk get name of startup disk Make 3 The standard application command Make is a request to create a new object that can include values for properties of the object.
C H A P T E R 3 Finder Commands propertyValue The value to assign to the property. Class: The value class of the property as specified in the object class definition in Chapter 2, “Finder Objects,” or a value that can be coerced to the class of the property Default value: If you create a file or folder without specifying its name, the Finder creates a an item named Untitled File or Untitled Folder.
C H A P T E R 3 Finder Commands If you save this script as an application and drag a folder onto the application’s icon, the script searches the entire startup disk for any items whose names include the name of the folder and creates alias files in that folder for all matching items: on open x tell application "Finder" repeat with i in x set n to name of i open i make alias file to every item of entire contents ¬ of startup disk whose name contains n at i end repeat end tell end open This script may take
C H A P T E R 3 Finder Commands Move 3 A Move command is a request to move an object or objects. The Finder version of the Move command is similar to the version described in the AppleScript Language Guide, except that the Finder’s Move command allows you to specify whether or not to replace items in the destination container.
C H A P T E R 3 Finder Commands You can use replacing existing items, with replacing, or replacing true instead of replacing conflicts without changing the meaning of this script. NOTES If an object specified by the referenceToObject parameter is located on a different disk from the container specified by the referenceToContainer parameter, the Move command copies the object instead of moving it, but doesn’t provide any warning that it has failed to remove the original object.
C H A P T E R 3 Finder Commands RESULT Reference to the opened object or a list of references.
C H A P T E R 3 Finder Commands SYNTAX print referenceToObject PARAMETER referenceToObject A reference to the object or objects to print—typically files or containers—or a list of references. Class: Reference or list of references RESULT Reference to the printed object or a list of references.
C H A P T E R 3 Finder Commands PARAMETER referenceToObject A reference to the object to put away or a list of references. Class: Reference or list of references RESULT Reference to the object put away or a list of references.
C H A P T E R 3 Finder Commands Quit 3 A Quit command is a request to quit the Finder application. The Finder’s Quit command is similar to the one described in the AppleScript Language Guide, except that the Finder ignores the parameters recognized by most other applications. You can’t tell other processes to quit from within a Tell statement addressed to the Finder. When you quit the Finder, any icons on the desktop and any Finder windows that are currently visible disappear.
C H A P T E R 3 Finder Commands allow you to relaunch the Finder with the Launch command (or with any Tell statement addressed to the Finder): tell application "Finder" to launch Restart 3 The Restart command is a request to restart the computer. It is equivalent to choosing Restart from the Special menu.
C H A P T E R 3 Finder Commands Reveal 3 The Reveal command is a request to make an object visible by opening its container and selecting it. If you specify objects in several containers, only the last specified object remains selected. SYNTAX reveal referenceToObject PARAMETER referenceToObject A reference to the object or objects to be revealed. Class: Reference or list of references RESULT Reference to the revealed object or a list of references.
C H A P T E R 3 Finder Commands Select 3 The Select command is a request to select one or more objects. If you specify objects in several containers, only the objects in the last specified container will remain selected. The container must be open for the specified object to be selected. SYNTAX select referenceToObject PARAMETER referenceToObject A reference to the object or objects to be selected.
C H A P T E R 3 Finder Commands Set 3 The Set command is a request to set the values of one or more objects. The Finder version of the Set command is identical to the standard version described in the AppleScript Language Guide. SYNTAX set referenceToObject to expression PARAMETERS referenceToObject A reference to the object whose value is to be set or a list of references. Class: Reference or list of references expression The expression whose value or values are to be assigned.
C H A P T E R 3 Finder Commands Shut Down 3 The Shut Down command is a request to shut down the computer. It is equivalent to choosing Shut Down from the Special menu. SYNTAX shut down PARAMETERS None RESULT None EXAMPLE tell application "Finder" to shut down Sleep 3 The Sleep command is a request to put a PowerBook to sleep. It is equivalent to choosing Sleep from the Special menu. Before putting the computer to sleep, the Finder displays a dialog box asking the user to confirm the decision.
C H A P T E R 3 Finder Commands PARAMETERS None RESULT None EXAMPLE tell application "Finder" to sleep Sort 3 The Sort command is a request for a sorted list of references. SYNTAX sort referenceList by propertyLabel PARAMETERS referenceList A list of references to the objects that are to be sorted. This may take the form of a single reference to several objects in the same container or a list of references to objects in several containers.
C H A P T E R 3 Finder Commands EXAMPLES This script returns a list of references to the folders in the startup disk, sorted by creation date: tell application "Finder" sort folders in startup disk by creation date end tell --result: {folder "Letters" of startup disk of application "Finder", folder "Projects" of startup disk of application "Finder", folder "Current Correspondence" of startup disk of application "Finder"} This script sorts files from several different folders by size.
C H A P T E R 3 Finder Commands Update 3 An Update command is a request to update an object and its elements, if any, to match their representation on disk. This involves making new items show up in the correct position and updating the desktop database. The Finder updates containers automatically when processing time is available; the Update command just causes it to happen immediately.
Appendixes
A P P E N D I X Figure A-0 Listing A-0 Table A-0 A Finder Commands at a Glance A This appendix summarizes the commands described in this guide and the placeholders used in syntax descriptions. For more detailed information about these commands, see Chapter 3, “Finder Commands.” The placeholder descriptions in the last section of this appendix define the placeholders used in the syntax summaries. Commands A Table A-1 summarizes the Finder commands descrfibed in this guide and their syntax.
142 clean up clean up Finder command syntax Commands ¬ Reference or list of references duplicate referenceToObject duplicate duplicate referenceToObject to referenceToLocation replacing ( conflicts | existing items ) duplicate referenceToObject to referenceToLocation None Integer or list of integers delete referenceToObject data size of referenceToObject as className data size of referenceToObject number of className ( in | of ) referenceToContainer number of className delete data size co
Commands move make get ¬ ¬ ¬ make [ new ] className at referenceToContainer with properties { propertyLabel:propertyValue [, propertyLabel:propertyValue ]...
144 Reference or list of references open referenceToObject open Commands Reference or list of references None Reference or list of references Reference or list of references Value or list of values None List of references Reference or list of references put away referenceToObject quit restart reveal referenceToObject select referenceToObject set referenceToObject to expression shut down sleep sort referenceList by propertyLabel update referenceToObject put away quit restart reveal select set shu
A P P E N D I X A Finder Commands at a Glance Placeholders A Table A-2 explains the placeholders used in the syntax descriptions in this appendix. Table A-2 Placeholders used in syntax descriptions Placeholder Explanation bitsToTest The value of the bits to test with the Computer command. className A class identifier or an expression that evaluates to a class identifier.
A P P E N D I X Figure B-0 Listing B-0 Table B-0 B Finder Errors B This appendix lists error numbers and error messages for errors returned by the Finder. For information about handling errors, see the AppleScript Language Guide.
Index Symbols C () in syntax descriptions xi [] in syntax descriptions xi | in syntax descriptions xi Calculate Folder Sizes property, of Views control panel 52 Capacity property, of a disk 58 classes, of parameters 100 Clean Up command 104–106 Clipboard property, of the Finder application 31 Closeable property, of a window 95 Close command 106–107 command definitions Clean Up 104–106 Close 106–107 Computer 107–109 Copy 109–110 Count 110–111 Data Size 111–113 Delete 113–114 Duplicate 114–115 Eject 115–11
I N D E X command definitions (continued) Sleep 134–135 Sort 135–136 Update 137 using 99–101 commands 99–137 parameters of 100 summarized 141–144 syntax of 99–100 Comment Heading property, of Views control panel 52 Comment property of an information window 70 of an item 73 Completely Expanded property, of a container 43 Computer command 107–109 Container object class 43–46 Container property of a container window 47 of an item 73 of a sharing window 85 Container Window object class 47–50 Container Window p
I N D E X Finder Application object class defined 31–37 introduced 18–25 Floating property, of a window 95 Folder object class 63–65 Folder property of a container window 47 of an item 73 of a sharing window 85 Font File object class 65–66 Fonts Folder property, of the Finder application 32 Font Suitcase object class 66–67 Free Space property, of a disk 58 Frontmost property of the Finder application 32 of a process 77 Icon Size property, of Views control panel 52 ID property, of an item 74 Index property
I N D E X M Make Changes property, of sharing privileges 83 Make command 121–123 Minimum Partition Size property 40 of an application file 38 of an information window 70 Modal property, of a window 95 Modification Date property of an information window 70 of an item 74 Mounted property of a sharable container 81 of a sharing window 86 Move command 124–125 N Name property of a group 68 of an item 74 of a process 77 of a user file 93 O object class definitions 26–97 Accessory Process 26–27 Accessory Suitca
I N D E X Physical Size property of an information window 71 of an item 74 placeholders, in syntax descriptions xi, 145 Position property of a group 68 of an item 74 of a user file 94 of a window 96 Preferences Folder property, of the Finder application 32 Previous List View property of a container 44 of a container window 48 Print command 126–127 Process object class 77–79 Product Version property of a file 62 of the Finder Application 33 of an information window 71 Protected property of a sharable contai
I N D E X Stationery property of a file 62 of an information window 71 Status Window object class 89–90 Suggested Partition Size property 40 of an application file 39 of an information window 71 Suitcase object class 90–91 syntax description defined 100 placeholders in xi, 145 System Folder property, of the Finder application 33 T Temporary Items Folder property, of the Finder application 34 Titled property, of a window 96 Trash-Object object class 91–93 Trash property, of desktop-object 56 typographic co
T H E A P P L E P U B L I S H I N G This Apple manual was written, edited, and composed on a desktop publishing system using Apple Macintosh computers and FrameMaker software. Proof pages were created on an Apple LaserWriter IINTX printer. Final page negatives were output directly from text files. PostScript™, the pagedescription language for the LaserWriter, was developed by Adobe Systems Incorporated. Text type is Palatino® and display type is Helvetica®. Bullets are ITC Zapf Dingbats®.