Plug-in Definition

The parameters that define the appearance of a scripted command, tool, or object plug-in are stored in a parameter record, which is associated with each object instance placed in the file. These records store persistent data between uses and provide default parameter values. A menu command that displays a dialog box, for example, might need to store values entered by a user for later use. A tool might provide several mode options in a popup list. Should the user wish to select a different mode for the tool, the new setting can be saved and reused on a subsequent use of the tool item. These values can be stored in the parameter record of the menu command or tool and retrieved later when the command or tool is selected again. Switching files will display stored values associated with the new files or, if no parameter record exists, will display the default values of the parameter record as created by the plug-in item.

The parameters for each object instance can be modified by using the Object Info palette to access the values in the object parameter record. A default parameter record is also created when the first instance of an object (or tool) is created in the file. This default parameter record, which is distinct from the parameter records associated with object instances, stores the object default settings with the file. It is used when placing subsequent object instances to define the defaults for each new object instance.

To define the custom plug-in parameters:

1. From the Plug-in Manager Custom Plug-ins tab, select the plug-in to define or edit.

2. Click Edit Definition.

The Edit Plug-in Definition dialog box opens.

3. When the plug-in parameters have been defined, click OK to return to the Plug-in Manager.

~~~~~~~~~~~~~~~~~~~~~~~~~

Specifying the Plug-in Script

Specifying the Plug-in Definition

Scripted Plug-ins

 

www.vectorworks.net