Model.panelcreation#

Model.panelcreation(collection, name, findPanel)#

Creates a panel entity.

Parameters:
  • collection (Collection) – The collection containing the input element entities.

  • name (hwString) – The name of the panel entity.

  • findPanel (int) –

    0 - Directly create the panel entity using the input elements

    1 - Find a panel consisting of these elements

Examples#

Create a panel named panel1 from elements with IDs 1 - 10#
import hm
import hm.entities as ent

model = hm.Model()

# Creating a collection that contains the elements with IDs 1-10
filter_elements = hm.FilterByEnumeration(ent.Element, list(range(1, 11)))
elements_collection = hm.Collection(model, filter_elements)

model.panelcreation(collection=elements_collection, name="panel1", findPanel=0)
Create a panel named panel1 from elements with IDs 1 - 10#
import hm
import hm.entities as ent

model = hm.Model()

# Creating a collection that contains the elements with IDs 1-10
filter_elements = hm.FilterByEnumeration(ent.Element, list(range(1, 11)))
elements_collection = hm.Collection(model, filter_elements)

model.panelcreation(collection=elements_collection, name="panel1", findPanel=1)