class anychart.core.ui.Callout Improve this Doc
Extends: anychart.core.VisualBase
Callout class.
Methods Overview
Specific settings | |
items() | Items settings. |
title() | Title settings. |
Coloring | |
background() | Background settings. |
Labels | |
hoverLabels() | Callout hover labels settings |
labels() | Callout labels settings |
selectLabels() | Callout select labels settings |
Size and Position | |
align() | Align settings. |
length() | Length settings. |
margin() | Margin settings. |
orientation() | Orientation settings. |
padding() | Padding settings. |
width() | Width settings. |
Methods Description
align
Getter for callout align settings.
Returns:
anychart.enums.Align | string - Callout align. See listing
var currentCallout = australiaMap.callout(); currentCallout.items(["AU.CT", "AU.WA", "AU.NS", "AU.SA"]); var calloutAlign = currentCallout.align();
Setter for callout align setting.
Params:
Name | Type | Default | Description |
---|---|---|---|
value | anychart.enums.Align | string | "center" | Callout align to set. |
Returns:
anychart.core.ui.Callout - Self instance for method chaining.Try it:
background
Getter for the callout background.
Returns:
anychart.core.ui.Background - Background instance. See listing
var currentCallout = australiaMap.callout(); currentCallout.items(["AU.CT", "AU.WA", "AU.NS", "AU.SA"]); var calloutBackground = currentCallout.background();
Setter for the callout background.
Params:
Name | Type | Description |
---|---|---|
value | string | Object | null | boolean | Background settings. |
Returns:
anychart.core.ui.Callout - Self instance for method chaining.Try it:
hoverLabels
Getter for callout hover labels.
Returns:
anychart.core.ui.LabelsFactory - Callout hover labels instance.Try it:
Setter for callout hover labels.
Detailed description
Callout labels get background settings from point which are attached and ignore their own settings.
Params:
Name | Type | Description |
---|---|---|
value | Object | boolean | null | Hover labels settings. |
Returns:
anychart.core.ui.Callout - Self instance for method chaining.Try it:
items
Getter for callout items.
Returns:
Array.<string> - An array of items id. See listing
var currentCallout = australiaMap.callout(); var calloutItems = currentCallout.items();
Setter for callout items.
Params:
Name | Type | Description |
---|---|---|
value | Array.<string> | Items as region id. |
Returns:
anychart.core.ui.Callout - Self instance for method chaining.Try it:
labels
Setter for callout labels.
Detailed description
Callout labels get background settings from point which are attached and ignore their own settings.
Params:
Name | Type | Default | Description |
---|---|---|---|
value | Object | boolean | null | true | Callout labels. |
Returns:
anychart.core.ui.Callout - Self instance for method chaining.Try it:
length
Getter for the callout length.
Returns:
null | number | string - The callout length. See listing
var currentCallout = australiaMap.callout(); currentCallout.items(["AU.CT", "AU.WA", "AU.NS", "AU.SA"]); var calloutLength = currentCallout.length();
Setter for the callout length.
Params:
Name | Type | Description |
---|---|---|
value | string | number | null | Callout length to set. |
Returns:
anychart.core.ui.Callout - Self instance for method chaining.Try it:
margin
Getter for the callout margin.
Detailed description
Also, you can use anychart.core.utils.Margin#bottom, anychart.core.utils.Margin#left,
anychart.core.utils.Margin#right, anychart.core.utils.Margin#top methods to setting paddings.
Returns:
anychart.core.utils.Margin - The callout margin.Try it:
Setter for the callout margin using a single value.
Params:
Name | Type | Description |
---|---|---|
value | Array.<(number|string)> | Object | Value to set. |
Returns:
anychart.core.ui.Callout - Self instance for method chaining.Try it:
Setter for the callout margin using several values.
Params:
Name | Type | Description |
---|---|---|
value1 | string | number | Top or top-bottom space. |
value2 | string | number | Right or right-left space. |
value3 | string | number | Bottom space. |
value4 | string | number | Left space. |
Returns:
anychart.core.ui.Callout - Self instance for method chaining.Try it:
orientation
Getter for the callout orientation.
Returns:
anychart.enums.Orientation | string - Callout orientation. See listing
var currentCallout = australiaMap.callout(); currentCallout.items(["AU.CT", "AU.WA", "AU.NS", "AU.SA"]); var calloutOrientation = currentCallout.orientation();
Setter for the callout orientation.
Params:
Name | Type | Default | Description |
---|---|---|---|
value | string | anychart.enums.Orientation | null | "left" | Callout orientation to set. |
Returns:
anychart.core.ui.Callout - Self instance for method chaining.Try it:
padding
Getter for the callout padding.
Detailed description
Also, you can use anychart.core.utils.Padding#bottom, anychart.core.utils.Padding#left,
anychart.core.utils.Padding#right, anychart.core.utils.Padding#top methods to setting paddings.
Returns:
anychart.core.utils.Padding - The callout padding.Try it:
Setter for the callout padding using a single value.
Params:
Name | Type | Description |
---|---|---|
value | Array.<(number|string)> | Object | Value to set . |
Returns:
anychart.core.ui.Callout - Self instance for method chaining.Try it:
Setter for the callout padding using several numbers.
Params:
Name | Type | Description |
---|---|---|
value1 | string | number | Top or top-bottom space. |
value2 | string | number | Right or right-left space. |
value3 | string | number | Bottom space. |
value4 | string | number | Left space. |
Returns:
anychart.core.ui.Callout - Self instance for method chaining.Try it:
selectLabels
Getter for callout select labels.
Returns:
anychart.core.ui.LabelsFactory - Callout select labels instance.Try it:
Setter for callout select labels.
Detailed description
Callout labels get background settings from point which are attached and ignore their own settings.
Params:
Name | Type | Description |
---|---|---|
value | Object | boolean | null | Select labels settings. |
Returns:
anychart.core.ui.Callout - Self instance for method chaining.Try it:
title
Setter for the callout title.
Detailed description
Sets callout title settings depending on parameter type:
- string - sets callout title text value.
- object - sets callout title settings.
Params:
Name | Type | Description |
---|---|---|
value | null | boolean | Object | string | Callout title. |
Returns:
anychart.core.ui.Callout - Axis title or itself for method chaining.Try it:
width
Getter for the callout width.
Returns:
number | string | null - The callout width. See listing
var currentCallout = australiaMap.callout(); currentCallout.items(["AU.CT", "AU.WA", "AU.NS", "AU.SA"]); var calloutWidth = currentCallout.width();
Setter for the callout width.
Params:
Name | Type | Description |
---|---|---|
value | number | string | Callout width to set. |
Returns:
anychart.core.ui.Callout - Self instance for method chaining.Try it: