The general node can display “decoration”
graphics in its top-left corner. Decorations are small graphic
objects used to represent the state of an object. For example, you
could use an icon to show that an error has occurred during the
processing of a workflow activity.
To add a decoration to a node, set the
decorations
property. The value of the property is an array of IlvGraphic objects.
The following code example shows a style sheet extract that adds a
decoration which is an IlvShadowLabel object.
Adding a decoration to a node in the style
sheet
node[status="error"] { decorations[0] : "@Subobject#errorDecoration"; } Subobject#errorDecoration { class : "ilog.views.sdm.graphic.IlvGraphicFactories$ShadowLabel"; IlvRect : "0,00,20,20"; label : "E"; foreground : "red" ; background : "white" ; }
The decorations are always displayed in the
upper-left corner of the node. The upper-left corner of the first
decoration is aligned with the upper-left corner of the node. If
several decorations are used, the subsequent decorations are
shifted to the right.