| Info : Actions
Graphics in OmniGraffle documents can have attached actions (URL links or AppleScript scripts) which can be activated by clicking them with the Browse tool. To attach an action to a graphic, select it and use the controls in the Action Info pane.
To attach a URL link, choose the Open a URL option, then type the URL in the text area below. You can test the URL by clicking the Open URL button below the text area. You can also create a URL link by dragging a URL from your web browser or a file from the Finder into the text area or onto the graphic itself. When using the browse tool, clicking a graphic with a URL action will open the URL using your preferred application for opening URLs of that type; for example, "mailto:" URLs will open in your email application, and "http:" URLs will open in your web browser. (To choose which applications open which types of URLs, use the Internet pane of System Preferences. See Mac Help for more information.) Clicking a graphic with a "file:" URL is equivalent to double-clicking the referenced file in the Finder. URL links are preserved when you export a document using the HTML Image Map setting.
To attach an AppleScript, choose the Run a Script option, then type the script in the text area below. (No "tell" block is necessary; the script will automatically target the OmniGraffle application. Also, you can reference the shape to which the script is attached with by the name "self".) You can check and run the script using the buttons below the text area. When using the browse tool, clicking a graphic with an attached AppleScript will run the script. If a script error is encountered, a sheet will appear explaining it.
Related Topics
| The Drawing Tools Table of Contents: Graphics Main Table of Contents