[ Team LiB ] |
Chapter 16. Global PropertiesThis chapter catalogues the global script properties of the AppleScript language. These are implemented by the AppleScript scripting component, which is present as the parent of the top-level script (see Section 9.7.3). They are globally accessible, as if your entire script started with property declarations for them. In case of a naming conflict, they can also be accessed like the properties of any visible script object, using the term AppleScript as the script object's name. For example: property pi : 3
display dialog AppleScript's pi -- 3.141592...
These are script properties like any other script properties, and as such:
The status of the global script properties is thus somewhat counterintuitive. You can accidentally (or intentionally) change their values, and then scripts that rely upon them to have their default values will not work. You would probably have expected things like pi and tab to remain constant. That's not the case—you can change their values—and furthermore if you change such a value in one script in a script editor application, the new value affects all scripts run in that script editor application, until you quit the application. |
[ Team LiB ] |