For example consider this three-terminal LDO symbol:

Let's look at each element of the drawing; annotations (not part of the original symbol) are draw with red:

The whole symbol is a group object with its role attribute set to symbol.

A. Terminal

A terminal is a group object with its role attribute set to terminal. The GUI and the compiler recognizes the group as terminal because of the role attribute value. Non-text drawing objects hosted by the terminal group will make connection to wires. (A wire is a drawing object, typically a line, in another group with attribute role=wire-net).

The terminal group is the child of the symbol group.

B. Decoration: random terminal label

It's common to print the purpose of the terminal next to the terminal, within the symbol body. In case of an MCU this often includes multiple port options. This can be done using a text object within the terminal group. The pen used is typically term-secondary, which is dark grey in the default sheet.

When the symbol is generated using boxsym-rnd the pin's name (specified on the "begin pin" line) is written there. It can be overridden using a pinlabel line within the pin.

C. Symbol decoration

Lines and other drawing objects directly within the symbol group are symbol decoration. They have only aesthetic function, e.g. drawing the body of the symbol. They normally use the sym-decor pen, which is green in the default sheet.

D. Terminal display name

This is the name of the terminal that is displayed on the sheet at the moment, and is exported in a netlist output. A terminal typically has multiple names:

The compiler will take the (concrete model) terminal and compile it into a port in the abstract model. The port will have a single name, called the display name. From all these input, there will be one selected for the display name. This selection also depends on the active view, e.g. in the raw view it's the original name attribute of the port, in the pcb view it's the pcb footprint pin number. The attribute it is stored in the port object is called display/name.

The actual text object is the child of the terminal group. The text object has the dyntext property set so that it can print the value of attributes. It will print "../a.display/name", which means:

In other words, the text object normally prints the abstract (compiled) object's display/name attribute, or in short, the display name.

E. Refdes printout

This is the name of the symbol. The text object, child of the symbol, typically uses the sym-primary pen and is a dyntext and prints ../A.name, which is the "name" attribute of the (concrete model) symbol group.

The text object normally uses the sym-primary pen, which is dark green in the default sheet.

Note: there's no "refdes" attribute. The symbol has a "name" attribute which donates the (only) name of the symbol. This is the same name that other systems tend to call refdes.

F. Random attribute printout

In this example the value of the footprint attribute is printed using a text object (with the dyntext property set). Such printouts are used to print:

The text object should use the sym-secondary pen.

G. Terminal line

The terminal group contains non-text drawing objects, typically a single line, for the actual terminal (but it could contain multiple lines and/or arcs and/or polygons as well). These are the active, sensitive objects of the terminal, the objects wires will connect to. These objects should use the term-decor pen.