Skip to content

ModelEleList

implementation of the model element list

ModelEleList

Canonical path: TypeCollections.ModelEleList.ModelEleList

Bases: list

implementation of the model element list

__getitem__

__getitem__(index: int) -> AllplanElement

get the model element by an index

Parameters:

  • index (int) –

    index

Returns:

__init__

initialize

Parameters:

append_geometry_2d

append_geometry_2d(
    geo_ele: ListModelEle2D | ModelEle2D | ModelEle2DList,
    com_prop: CommonProperties | None = None,
)

append a 2D geometry element to the list

Parameters:

  • geo_ele (ListModelEle2D | ModelEle2D | ModelEle2DList) –

    2D geometry element

  • com_prop (CommonProperties | None, default: None ) –

    common properties

append_geometry_3d

append_geometry_3d(
    geo_ele: ListModelEle3D | ModelEle3D | ModelEle3DList | Curve3DList,
    com_prop: CommonProperties | None = None,
)

append a 3D geometry element to the list

Parameters:

  • geo_ele (ListModelEle3D | ModelEle3D | ModelEle3DList | Curve3DList) –

    3D geometry element

  • com_prop (CommonProperties | None, default: None ) –

    common properties

append_geometry_3d_with_texture

append_geometry_3d_with_texture(
    geo_ele: ListModelEle3D | ModelEle3D | ModelEle3DList | Curve3DList,
    texture_def: TextureDefinition,
    com_prop: CommonProperties | None = None,
)

append a 3D geometry element to the list

Parameters:

  • geo_ele (ListModelEle3D | ModelEle3D | ModelEle3DList | Curve3DList) –

    3D geometry element

  • texture_def (TextureDefinition) –

    texture definition

  • com_prop (CommonProperties | None, default: None ) –

    common properties

set_color

set_color(color: int)

set the color

Parameters:

  • color (int) –

    color

set_common_properties

set_common_properties(com_prop: CommonProperties)

set the common properties

Parameters:

set_element_attributes

set_element_attributes(index: int, attributes: list[Attribute])

set the attributes to the element with the defined index

Parameters:

  • index (int) –

    index

  • attributes (list[Attribute]) –

    attributes

set_pen

set_pen(pen: int)

set the pen

Parameters:

  • pen (int) –

    pen

set_stroke

set_stroke(stroke: int)

set the stroke

Parameters:

  • stroke (int) –

    stroke