Magic-7.3 Command Reference

#

## what

Print out information about what material is in the current selection. Short summary.

### Shortcuts:

> Key macro / (slash) implements the command what.

### Usage:

> what [-list[all]]

### Summary:

> The what command queries what material is in the current selection. This includes a report on layers, labels, and subcell instances that are selected.

> In the Tcl version of magic, the -list option returns the result as a Tcl list containing three sub-lists. The first sub-list contains the types found, the second contains the labels found, and the third contains the subcells found. Each label in the second sub-list is itself a list of three items: The label text, the layer the label is attached to, and the cell def containing the label. Each subcell in the third sub-list is itself a list of two items: The subcell instance ID name, and the cell definition name.

> -listall is a variant of the Tcl list, in which the first sub-list contains the types found, where each entry is itself a list. Each list entry first item is the name of the layer, and the second entry is a list containing the names of all subcells where that type is found.

### Implementation Notes:

> what is implemented as a built-in command in magic.

Return to command index

Last updated: March 24, 2021 at 3:30pm