Top
You are looking at an outdated 7.1.1 version of this document. Switch to the 8.0.1 version to see the up to date information.

class anychart.elements.Tooltip Improve this Doc

Extends: anychart.Base

Methods Overview

Miscellaneous
allowLeaveScreen()Allow tooltip to leave screen when moving.
anchor()Gets or sets Tooltip anchor settings.
background()Tooltip background.
content()Tooltip content.
contentFormatter()Function to format content text.
enabled()Enabled for tooltip.
hide()Show tooltip using textInfo and position info objects.
hideDelay()Sets/gets delay in milliseconds before tooltip becomes invisible on visible(false) call.
isFloating()Defines whether tooltip follows the mouse or not.
offsetX()Offset by X of tooltip position.
offsetY()Y offset of tooltip position.
padding()Tooltip padding.
separator()Tooltip title separator.
show()Show tooltip using textInfo and position info objects.
title()Tooltip title.
titleFormatter()Function to format title text.

Methods Description

allowLeaveScreen

Allow tooltip to leave screen when moving.

Params:

Name Type Description
value boolean Allow tooltip to leave screen when moving.

Returns:

boolean anychart.elements.Tooltip - Allow tooltip to leave screen when moving or itself for method chaining.

anchor

Gets or sets Tooltip anchor settings.

Params:

Name Type Description
value anychart.enums.Anchor | string Tooltip anchor settings.

Returns:

anychart.elements.Tooltip anychart.enums.Anchor - Tooltip anchor settings or itself for method chaining.

background

Tooltip background.

Params:

Name Type Description
value anychart.elements.Background | Object | string | null Tooltip background settings.

Returns:

anychart.elements.Background anychart.elements.Tooltip - Background instance or itself for method chaining.

content

Tooltip content.

Params:

Name Type Description
value anychart.elements.Label | Object | string | null Content settings.

Returns:

anychart.elements.Label anychart.elements.Tooltip - Labels instance or itself for method chaining.

contentFormatter

Function to format content text.

Params:

Name Type Description
value function Function to format content text.

Returns:

function anychart.elements.Tooltip - Function to format content text or itself for method chaining.

enabled

Enabled for tooltip.

Params:

Name Type Description
value boolean

Returns:

anychart.elements.Tooltip boolean -

hide

Show tooltip using textInfo and position info objects.

Returns:

anychart.elements.Tooltip - Itself for method chaining.

hideDelay

Sets/gets delay in milliseconds before tooltip becomes invisible on visible(false) call.

Params:

Name Type Description
value number Delay in milliseconds before tooltip becomes invisible on visible(false) call.

Returns:

number anychart.elements.Tooltip - delay in milliseconds before tooltip becomes invisible on visible(false) call or itself for method chaining.

isFloating

Defines whether tooltip follows the mouse or not.

Params:

Name Type Description
value boolean Follow the mouse or not.

Returns:

boolean anychart.elements.Tooltip - Follow the mouse or itself for method chaining.

offsetX

Offset by X of tooltip position.

Params:

Name Type Description
value number New value of X offset of tooltip position.

Returns:

number anychart.elements.Tooltip - X offset of tooltip position of itself for method chaining.

offsetY

Y offset of tooltip position.

Params:

Name Type Description
value number New value of Y offset of tooltip position.

Returns:

number anychart.elements.Tooltip - Y offset of tooltip position of itself for method chaining.

padding

Tooltip padding.

Params:

Name Type Description
value anychart.utils.Padding | Object | string | null Tooltip padding settings.

Returns:

anychart.utils.Padding anychart.elements.Tooltip - Padding instance or itself for method chaining.

separator

Tooltip title separator.

Params:

Name Type Description
value anychart.elements.Separator | Object | string | null Tooltip separator settings.

Returns:

anychart.elements.Separator anychart.elements.Tooltip - Separator instance or itself for method chaining.

show

Show tooltip using textInfo and position info objects.

Params:

Name Type Description
textInfo Object Object with info about series and charts to format title and content text.
position anychart.graphics.math.Coordinate Position of a tooltip.

Returns:

anychart.elements.Tooltip - Itself for method chaining.

title

Tooltip title.

Params:

Name Type Description
value anychart.elements.Title | Object | string | null Tooltip settings.

Returns:

anychart.elements.Title anychart.elements.Tooltip - Title instance or itself for method chaining.

titleFormatter

Function to format title text.

Params:

Name Type Description
value function Function to format title text.

Returns:

function anychart.elements.Tooltip - Function to format title text or itself for method chaining.