Object templates
In the Project Environment dialog, in [library or project] > Diagram > Object Templates, the project administrator can define what kinds of diagram symbols designers can insert into diagrams.
A diagram object template defines the following:
- Type of the object. This also defines the database structure of the object.
- Prefix for position IDs (PosId).
- Graphical symbol or linetype.
- Data to be stored in the database. (A part of it comes from the set_defaults script.)
Creating a new diagram object template
The project administrator must create a Diagram Object Template for each diagram symbol that is to be used by diagram designers.
Do the following:
-
If the diagram object template is to use a graphical 2D symbol, make sure the symbol exists in [library or project] > Document Production > 2D Symbols and approve it for the project, if needed. See 2D Symbols.
-
If the diagram object template is to create connection lines, make sure the required linetype exists in [library] > Configuration > Common. See Linetypes.
-
If the diagram object template is to have a special icon in the object browser, make sure the icon exists in [library or project] > Resources > Icons. See Icons.
-
In the Project Environment dialog, in Diagram > Object Templates, select New > Diagram Object Template and create the new template with Diagram Object Template Edit.
Tip: Often the easiest way to make a new template is to copy-paste an existing template. Then the properties such as type and sub-table are copied from the original template.
-
Add any required data to the COMPLOOKUP table. See Component lookup table.
-
Create new labels, if needed. See P&ID Custom Labels.
Diagram Object Template Edit
In the Diagram Object Template Edit dialog, you can define the properties of the diagram object template. The settings that are displayed in this dialog depend on the object type that the template represents.
Setting |
Description |
---|---|
PD object type Description |
The top of the dialog displays the type of the diagram object template you are creating or editing, such as "Armature" or "Equipment". In the description field, enter a name that describes the function of the thing that the diagram object template represents, such as "Safety valve". This is the name that designers see in the P&ID application—see Template. |
Icon |
If you want to use a special icon for the diagram object template, select this option and click Select to select the icon. For more information on icons, see Icons. |
Menu Item Data |
Defines the prefix for the position ID and the lookup key for retrieving pre-fill data from the COMPLOOKUP table.
For more information on COMPLOOKUP, see Component lookup table. |
Sub Table |
This setting defines the database sub-table of the diagram object template, such as VALVES. Select the sub-table to use. |
Category |
This field displays the old menu directory in environments that have been converted from CADMATIC version 4.x. If you are creating a new diagram object template, you can leave this field empty. |
2d symbol of the object |
This setting is displayed for diagram object templates that display a graphical symbol in the diagram. The field must contains the exact name of the 2D symbol. You can either type the name or select the symbol from COS. The object template preview shows what the selected graphic looks like. |
2D linetype of object |
This setting is displayed for diagram object templates that are used to draw a connection line between other diagram objects: Cable, Iline, or Pipeline. The selection field lists the available Linetypes and Multiline styles. The object template preview shows what the selected linetype looks like. |
Attributes for Template |
You can select which attributes the diagram object template should have. You can only select attributes that have been assigned to the "Diagram Object Template" object type in COS. |