Home Forums Chart Support Displaying every word in label of x-Axis on new line

Displaying every word in label of x-Axis on new line

Viewing 2 posts - 1 through 2 (of 2 total)
  • #5478

    code snippet:-
    dataPoints: [
    { x: 10, y: 71,label:”Try Alpha 1″, },
    { x: 20, y: 55,label:”Try Alpha 2″,},
    { x: 30, y: 50,label:”Try Alpha 3″, },
    { x: 40, y: 65,label:”Try Alpha 4″, },
    { x: 50, y: 95,label:”Try Alpha 5″, },
    ]

    How to show every word of “Try Alpha 1” on new line. Like:-

    Try
    Alpha
    1

    #5480

    You can use labelMaxWidth property of axisX/axisY. Below is an example.

    http://jsfiddle.net/canvasjs/UJD3f/

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.