A5.chart.guides.annotationDefinition Text Object
Description
The definition of a text annotation.
Discussion
The "text" annotation can be used to add arbitrary HTML to the chart. This HTML is located relative to the plot area, and can optional be either explicit relative to the area, or implicit relative to the axes. This can be used to add text to points of interest, or a title to the chart.
Properties
- locationstringobject
The location of the text. See A5.chart Definition Location Object.
- alignstring
How to align the text relative to the location. Values can be "center", "above", "below", "before", "after", "adj-above", "adj-below", "adj-before" and "adj-after". Multiple alignments can be applied by combining values using spaces (for example "above after"). The "adj" prefix will make the given alignment occur after the rotation (if any) has been applied.
- rotatenumber
The rotation (in degrees) to apply to the text.
- offsetobject
The offset of the text.
- majornumber
The major offset relative to the alignment. The default value is 0.
- minornumber
The minor offset relative to the alignment. The default value is 0.
- htmlstringfunction(data,temp)
The HTML text to display. A function called with "data" (see A5.chart Render Data Object) and "temp" can be used to dynamically calculate the HTML.
- classNamestringfunction(data,temp)
The class name to add to the text element. A function called with "data" (see A5.chart Render Data Object) and "temp" can be used to dynamically calculate the class name.
- stylestringfunction(data,temp)
The style to add to the text element. A function called with "data" (see A5.chart Render Data Object) and "temp" can be used to dynamically calculate the style.
- attrsstringfunction(data,temp)
The attributes to add to the text element. A function called with "data" (see A5.chart Render Data Object) and "temp" can be used to dynamically calculate the attributes.
- tipstringfunction(data,temp)
The mouseover tip to add to the text element. A function called with "data" (see A5.chart Render Data Object) and "temp" can be used to dynamically calculate the tip.