Sets the attribute value(s) for the specified object.
set_attribute([id,] object_type, values)
-
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"
-
values - the attribute values to set. They may be specified
as an attribute object structure, an attribute string, or a
list of attribute-value pairs.
The set_attribute command is used to set one or more values of
the attributes of the specified object. Multiple ovbjects of
the same type may be modified with a single command by setting
the currency to "all".
For general information on specifying attribute values, refer
to
"ahelp attributes"
and
"ahelp setget"
.
chips> set_attribute('crv2',chips_curve,'line.style=dot
line.thickness=2')
Set the curve line style to dot and the thickness to 2.
chips> set_attribute(chips_plot,['style','box'])
Using attribute/value pairs, set the plot style to box.
chips> settings = ChipsContour()
chips> settings.color = 'red'
chips> settings.style = 'shortdash'
chips> set_attribute('ctr1',chips_contour,settings)
Populate the "settings" structure with attribute
values, then use it to set ctr1 to be a red, short-dashed
contour.
|