ChartLabel Constructor

Syntax

PP.Ui.ChartLabel(settings: Object);

Parameters

settings. JSON object that contains values of component properties.

Description

The ChartLabel constructor creates an instance of the ChartLabel class.

Example

To execute the example, the HTML page must contain the BubbleChart component named bubbleChart (see Example of Creating the BubbleChart Component). Create a new text label for the bubble chart and render this label:

// Get chart area
var chartArea = bubbleChart.getChartArea();
// Create a new label
var label = new PP.Ui.ChartLabel({
    Alignment: PP.VerticalAlignment.Top,
    Direction: PP.Ui.TextDirection.LeftToRight,
    NoDataText: "No data",
    ShowHandCursor: true,
    TextWrapping: PP.Ui.TextWrapping.NoWrap,
    Text: "New label"
});
// Draw the label
label.draw(false, chartArea.getHistoryLayer());

After executing the example a text label is drawn:

See also:

ChartLabel