Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Highcharts footer spacing

Tags:

highcharts

Using Highcharts I want to put footer text under the chart. The only way I could see to do this is to use the credits attribute. But with long text it looks cramped. Is there a way to style the credits to add spacing?

http://jsfiddle.net/QbEvN/

    credits: {
        position: {
            align: 'center'
        },
        text: 'this is some really long text that i am using as a footer',
        href: null
    },
like image 499
linojon Avatar asked Feb 16 '23 19:02

linojon


1 Answers

If you have your heart set on leveraging the credits options for your footer. Here's some options you can use to space it as you desire:

    chart: {
        marginBottom: 100 //space from axis to chart bottom
    },
    legend: {y: -20}, // position between axis and legend

    credits: {
        text: 'This is so super duper uper long text. Look at all this space!',
        position: {
            align: 'center',
            y: -5 // position of credits
        },
        style: {
            fontSize: '14pt' // you can style it!
        }
    },

Fiddle here.

enter image description here

like image 144
Mark Avatar answered Mar 03 '23 09:03

Mark