If you implement Apple events so that they translate into logical and useful AppleScript scripts, your implementation will probably work well with other scripting components that resemble AppleScript. The manner in which the AppleScript component uses the information in 'aete' resources depends on specific characteristics of the AppleScript scripting language. An AppleScript expression consists of an internal compiled form and corresponding expressions in dialects, or versions of the AppleScript scripting language that resemble different human languages. Users can select the dialect they want to use from within the Script Editor application. If a script is displayed in a window and the user selects a different dialect, the AppleScript component converts the script to the new dialect.
Users can install additional dialects as necessary.
This section describes how the AppleScript component uses the information in the 'aeut' and 'aete' resources, not how it obtains that information. Figure 7-5 shows how the AppleScript component uses information from its 'aeut' resource and an application's 'aete' resource to execute a script that consists of AppleScript statements displayed in a script editor window. The AppleScript component then evaluates each expression and performs actions or sends Apple events as appropriate. The AppleScript component can then decompile and display this value in the script editor window, assign it to a variable, or otherwise manipulate it according to the rest of the script. When the AppleScript component evaluates the compiled expression, it creates and sends a Print event whose direct parameter is an object specifier record that the SurfWriter application can resolve as the specified chart.