create_rectangle#
- Modeler2D.create_rectangle(position, dimension_list, is_covered=True, name=None, matname=None, non_model=False, **kwargs)[source]#
Create a rectangle.
- Parameters:
- position
list
of
float
Position of the lower-left corner of the rectangle
- dimension_list
list
of
float
List of rectangle sizes: [X size, Y size] for XY planes or [Z size, R size] for RZ planes
- is_coveredbool
Specify whether the ellipse is a sheet (covered) or a line object
- name
str
, default=None Name of the object. The default is
None
. IfNone
, a unique name NewObject_xxxxxx will be assigned)- matname
str
, default=None Name of the material. The default is
None
. IfNone
, the default material is assigned.- non_modelbool,
optional
Either if create the new object as model or non-model. The default is
False
.
- position
- Returns:
References
>>> oEditor.CreateRectangle
Examples
>>> rect1 = aedtapp.modeler.create_rectangle([0, -2, -2], [3, 4]) >>> rect2 = aedtapp.modeler.create_rectangle(position=[0, -2, -2], dimension_list=[3, 4], ... name="MyCircle", matname="Copper")