The SD-AM-REGISTER-SYMBOL function is used to register symbols for use in the Creo Elements/Direct Annotation Symbols Browser. All symbol definitions are made with this function, including those defined in the Creo Elements/Direct Annotation interface. The Write Symbol Registration command saves the current SD-AM-REGISTER-SYMBOL functions to a file.
Symbols are defined with a name, a creation dialog name, and a file name (for file-based symbols). A category and edit dialog name can also be given, as well as a predefined pixmap to be seen in the Symbols Browser.
The registration functions can be included in the am_customize file or in a separate file. To load a file into Creo Elements/Direct Annotation, enter (load "path / filename") in the user input line, where path / filename is the file and its path containing valid SD-AM-REGISTER-SYMBOL functions.
You can also enter a SD-AM-REGISTER-SYMBOL function in the user input line. Be sure to use unique names for the symbol "metaname".
Further information and additional functions on customized symbols are provided in the Integration Kit documentation.
The SD-AM-REGISTER-SYMBOL function, its options, and related functions are listed below. See the individual links for information about them. An
Example is given below.
:META-NAME specifies the name by which the symbol is to be known in the Symbols Browser. The name must be unique; de-register a previous instance of a metaname to register it again.
Syntax
-->(:META-NAME)----->|"metaname"|------->
PIXMAP-FILE option
:PIXMAP-FILE specifies a pixmap or bitmap file to include in the symbol's entry in the Symbols Browser. The file can be produced in any standard pixmap editor, such as XPaint. The recommended size for a pixmap is 90 by 24 pixels.
Syntax
-->(:PIXMAP-FILE)----->|"filename"|------->
CREATE-DIA option
:CREATE-DIA specifies the dialog function called to create the symbol. The dialog is opened when the symbol entry is selected in the Symbols Browser.
Syntax
-->(:CREATE-DIA)----->|"dialog function name"|------->
EDIT-DIA option
:EDIT-DIA specifies the dialog function called when the symbol is edited. When no edit dialog is specified, the default Edit Symbol dialog is called.
Syntax
-->(:EDIT-DIA)----->|"dialog function name"|------->
CATEGORY option
:CATEGORY specifies an existing or new category in which to place the registered symbol. Symbol categories can also be edited, added, and removed in the Symbols Browser.
Syntax
-->(:CATEGORY)----->|"category name"|------->
FILE-NAME option
:FILE-NAME specifies the file used for file-based symbols. When the symbol is created on the drawing, the named file provides the symbol data.
Syntax
-->(:FILE-NAME)----->|"filename"|------->
SD-AM-UNREGISTER-SYMBOL-ALL function
The SD-AM-UNREGISTER-SYMBOL-ALL function de-registers all previously defined symbols. In the am_customize file (or in a separate file), use this function before instances of SD-AM-REGISTER-SYMBOL if you do not want the default symbols to be available.
SD-AM-UNREGISTER-SYMBOL function
The SD-AM-UNREGISTER-SYMBOL function de-registers a previously-defined symbol. You can specify any existing symbol metaname, enclosing it within double quotes.
Syntax
(SD-AM-UNREGISTER-SYMBOL "metaname")
Example
The following is an example of a symbol registration: