Box

class ipkiss3.all.Box

A rectangular layout element defined via its center coordinate and extent in x and y, drawn on a given layer.

Parameters:
layer: __Layer__, required

Layout layer on which the element needs to be placed

box_size: Coord2 and number >= 0, optional

Size of the box

center: Coord2, optional

Center of the box

transformation: GenericNoDistortTransform, optional

Notes

The center coordinate (center) defaults to (0.0, 0.0). The extent in x and y (box_size) defaults to (1.0, 1.0). The flat_copy() method of an IPKISS i3.Box will return a Boundary element if a rotation is present and an ElementList object otherwise. A Box in GDSII format is defined via 5 vertices, the first and last being identical. If a rotation is present, an IPKISS i3.Box will be exported to GDSII as a (rotated) Boundary element and as a (GDSII) Box otherwise. If a rotated GDSII Box (edges not aligned with X/Y axes) is encountered on import, a warning is thrown and it is imported as Boundary element instead.

size_info(layers=None)

Returns the SizeInfo object corresponding to the footprint of this element.

Parameters:
layers: list, optional

The layers to be included, default is None (all layers)

Returns:
SizeInfo object
convex_hull()

returns the Shape object corresponding to the complex hull of this Element

Returns:
Shape object
flat_copy(level=-1)

Returns a flattened copy of the Element. (recursive)

Parameters:
levelHow many levels deep should the element be flattened. -1 means all levels (default)
Returns:
Boundary element if transformation has a nonzero rotation, ElementList object otherwise
is_empty()

returns True if the content of the Element is empty