GetElementHeader
Returns the header data of a given element, which contains the main informations of the element.
def GetElementHeader (elemGuid) -> APIObject
Parameters
- elemGuid
- [in] GUID of an element.
Return Values
This function returns an APIObject describing the header (main informations) of the Element.
Remarks
This function is analogous to the ACAPI_Element_GetHeader function of the C++ API.
For information on how to interpret the returned APIObject, visit the C++ documentation.
Example
# Move all morphs to the "Morph - General" layer morphLayer = SearchAttributeByName(API_LayerID, "Morph - General") count = 0 with UndoScope("Changing Layer of Morphs"): for morphGuid in GetElementList(API_MorphID): morphHeader = GetElementHeader(morphGuid) if morphHeader.layer != morphLayer.index: morphHeader.layer = morphLayer.index ChangeElementHeader(morphHeader) count += 1 print("Changed {} Morph(s)".format (count))
Requirements
- Version: Python API 0.1 or Later
- Module: GS