Retrieves attribute value(s) for an object.
get_attribute([id,] object_type [,attribute])
-
id - an optional ChipsId structure containing values to
modify the currency state for the command or a string id to
specify the object
-
object_type - what type of object to modify, such as
chips_window or chips_curve; see the Object Type section of
"ahelp chipsopt"
-
attribute - an optional string containing the name of the
attribute to retrieve
The get_attribute command retrieves the value of a specific
attribute. If an attribute is not specified, the values of
all attributes of the specified object are returned.
The command can only operate on a single object. An
error is returned if currency is set to "all".
Some values are set to "None" in the returned structure.
These entries generally correspond to attributes which may
only be modified at creation time, such as the object id.
chips> crvatt = get_attribute(chips_curve)
chips> print(crvatt)
Retrieve a structure containing the attribute values of
the current curve and store the results in "crvatt". Print
the contents of "crvatt".
chips> get_attribute('win1','bgcolor')
Retrieve the "bgcolor" value for "win1".
|