From FreeCAD Documentation
API degli Oggetti
Essendo parametrici, in FreeCAD gli oggetti del documento possono avere un sacco di altre proprietà. Queste sono quelle di base, presenti in ogni FreeCAD Document Object. Gli oggetti possono essere recuperati semplicemente con il loro nome. Esempio:
myObj = FreeCAD.ActiveDocument.myObjectName
print myObj.PropertiesList
Content
Returns: an XML representation of the properties of an object.
Label
Returns: Gets/sets the objects label. The string can be unicode.
Name
Returns: the unique name of an object.
Placement
Returns: Gets/sets the Placement of an object. A placement defines an orientation (rotation) and a position (base) in 3D space. It is used when no scaling or other distortion is needed.
PropertiesList
Returns: a list of the properties of an object
State
Returns: the FreeCAD state of an object (ie. if it needs to be recomputed)
Type
Returns: a string describing the type of an object
ViewObject
Returns: the associated View Provider (FreeCADGUI object) of an object
getAllDerivedFrom( )
Description:
Returns: all descentences of this object
getDocumentationOfProperty( )
Description:
Returns: the documentation string of the property of this class.
getGroupOfProperty( )
Description:
Returns: the name of the group which the property belongs to in this class. The properties sorted in differnt named groups for convenience.
getPropertyByName( )
Description:
Returns: the value of a named property.
getTypeOfProperty( )
Description:
Returns: the type of a named property. This can be (Hidden,ReadOnly,Output) or any combination.
isDerivedFrom( )
Description:
Returns: True if given type is a father
purgeTouched( )
Description: Marks the object as unchanged
Returns:
touch( )
Description: Marks the object as changed (touched)
Returns:
Altre lingue: