diff --git a/src/ifcopenshell-python/docs/ifcopenshell-python/selector_syntax.rst b/src/ifcopenshell-python/docs/ifcopenshell-python/selector_syntax.rst index a21594ace5..e322ac675c 100644 --- a/src/ifcopenshell-python/docs/ifcopenshell-python/selector_syntax.rst +++ b/src/ifcopenshell-python/docs/ifcopenshell-python/selector_syntax.rst @@ -186,6 +186,7 @@ Valid keys are: "``material`` or ``mat``", "Gets the assigned material, which may be a material set." "``item`` or ``i``", "If the previous key returns a material set, gets the relevant material set items" "``materials`` or ``mats``", "Gets a list of IfcMaterials assigned directly or indirectly (such as via a material set) to the element" + "``profiles``", "Gets a list of IfcProfileDefs assigned (such as via a material profile) or used (such as in an extrusion) in the element" "``x``", "Gets the X coordinate of the element's placement" "``y``", "Gets the Y coordinate of the element's placement" "``z``", "Gets the Z coordinate of the element's placement" diff --git a/src/ifcopenshell-python/ifcopenshell/util/selector.py b/src/ifcopenshell-python/ifcopenshell/util/selector.py index d713a331c4..582879f9d3 100644 --- a/src/ifcopenshell-python/ifcopenshell/util/selector.py +++ b/src/ifcopenshell-python/ifcopenshell/util/selector.py @@ -970,6 +970,8 @@ class Selector: value = ifcopenshell.util.element.get_material(value, should_skip_usage=True) elif key in ("materials", "mats"): value = ifcopenshell.util.element.get_materials(value) + elif key == "profiles": + value = ifcopenshell.util.shape.get_profiles(value) elif key == "styles": value = ifcopenshell.util.element.get_styles(value) elif key in ("item", "i"):