Accessibility
[an error occurred while processing this directive]

Create Illustrator actions


Table of Contents

Inserting Menu Items You can also use the Insert Menu Item command from the Actions palette menu. This opens the Insert Menu Item dialog box, as shown in Figure 6. Although the instructions say you can type the first few characters of a menu command in the field or use the Find button, I find it much easier to just move to a menu and choose the item you want to insert. This inserts the full path name in the field.

ill10ppactions_fg6

Figure 6: The Insert Menu Item dialog box allows you to add menu items that cannot be recorded while creating the action.

The Insert Menu Item command is extremely helpful for including in an action any items from the Effect menu that can’t be captured as part of the recording. For instance, the Twist effect must be inserted using the Insert Menu Item. Sadly, all menu items inserted from the Insert Menu Item must be stopped with a dialog box. So there is no way to run the action without getting the dialog box.

Inserting Paths As you create actions, you may notice that although rectangles and ellipses can be made part of an action, paths created with the pen, brush, or pencil tool cannot be recorded. These paths rely on recording the mouse movements, which unfortunately cannot be made part of an action. Fortunately, you can insert simple paths as part of an action using the Insert Select Path command.

As you are recording the action, draw the path. With the path still selected, choose Insert Select Path from the Actions palette menu. In the Actions palette you will see the phrase Set Work Path appear. This indicates that the path will be created at that point. Once you have made the path part of the action, you can then modify it using any of the recordable action commands such as transformations, opacity settings, and so on.

Congratulations—you’ve just selected and deleted a path within an action. And they said it couldn’t be done! Your steps should be listed in the Actions palette, as shown in Figure 8.

Selecting Paths You may also notice that selections made with any of the selection tools cannot be recorded. Fortunately, the generous engineers at Adobe added the Select Object command. This command allows you to use the little-known Note options box in the Attributes palette to select objects.

The best way to understand how the Select Object command works is to use it to create an action. Here, I’ll create one to perform a cleanup task that I always think is a good idea and never want to take the time to do. When you use the Offset Path command, Illustrator creates a copy of the selected path, but it doesn’t delete the original—a perfect opportunity for an action! (Thanks to Dave Burkett, group product manager, who posted this action way back when actions were first introduced into Illustrator.)

  1. Select a path and start a new action.

    Click the New Action icon to open the New Action dialog box. I named the path Delete Offset Path, and then clicked Record to start recording the action.

  2. Add a note to the selected path.

  3. Use the Note options box of the Attributes palette to add a note that tags the object with a word, as shown in Figure 7. It doesn’t matter what the note says; I just happen to like to use the word original.

    ill10ppactions_fg7

    Figure 7: By typing a note in the Attributes palette (left), you make it possible to choose Select Object in the Actions palette to open the Set Selection dialog box (right) to delete that object later.

  4. Press Enter (Return on the Mac) to apply the note.

  5. The note is not made part of the action until you press the Enter key. You’ll see the note added with the label “Attribute Setting” in the Actions list.

  6. Choose Object > Path > Offset Path.

  7. Make whatever settings you want in the dialog box and click OK. The new path appears offset from the original. Delete the note word from the Attributes palette and press Enter (Return on the Mac).

  8. When you offset the path, the same note is applied to the new path. With that path still selected, you need to delete the second note so that only the original object has the note applied to it. (There can be only one original, right?) Select the note in the options box and delete it. Don’t forget to press the Enter key to set the step in the Actions palette.

  9. Choose Select Object from the Actions palette.

  10. This opens the Set Selection dialog box, as shown in Figure 7. Type the same word you used to label the original object. (See why I like the word original?) Click OK. This selects the original object.

  11. Press the Backspace key (Delete key on the Mac) on the keyboard.

  12. This deletes the original object, leaving only the path that was offset from the original.

  13. Click the Record button to stop recording.

    Congratulations—you’ve just selected and deleted a path within an action. And they said it couldn’t be done! Your steps should be listed in the Actions palette, as shown in Figure 8.

    ill10ppactions_fg8

    Figure 8: The steps created by the Delete Offset Path exercise. I've opened the triangles to show you the details for each of these steps.

  14. I admit, it may seem like a lot of work; but trust me—once you’ve created the action, it’s so much easier to just run it than executing the individual steps by hand. And with a function key applied to the action, it is just as easy to execute the action as it is to run the Offset Path command.

Excerpted from “Real World Adobe Illustrator 10”, Copyright ©2002 by Deke McClelland, published by Adobe Press in association with Peachpit Press. Used with the permission of Pearson Education and Peachpit Press. To buy this book, visit www.peachpit.com.