It looks like you're new here. If you want to get involved, click one of these buttons!
Hi
In layer1/0, I have many shapes, namely polygons and boxes. All the boxes are of the same size and they are all squares. How can I obtain the side length of a box, such as the side length of the box in the red frame?
Comments
You cannot directly. DRC is for checking thresholds, not for measuring.
You can iterate the objects in a layer:
"poly" will be a
DPolygon
object (https://www.klayout.de/doc-qt5/code/class_DPolygon.html).The reverse of "each" is "insert":
This basically allows you to create custom DRC functions. But those will not be very efficient as they are executed inside the script engine.
Matthias