soka
Posts: 10
Joined: Wed Oct 25, 2023 7:48 am

Gantt with text-frames under years

Hi,

I did some Gantt charts over the time.

Now I want to add a text-field below the year specification as shown in the illustration attachment.

Is this possible?

Regards,
Søren
andrzej.b
Site Moderator
Posts: 570
Joined: Mon Jul 15, 2024 12:34 pm

Re: Gantt with text-frames under years

Hi Søren,

Thanks for contacting us with your question!

As your graphic is not visible in the post, I'm improvising a bit, but it should work anyhow - you can use SVGRenderer API do add custom text anywhere on the chat, please see the documentation: https://www.highcharts.com/docs/advance ... s/renderer

I have prepared a sample fiddle for you: https://jsfiddle.net/BlackLabel/jc4d5s63/

Let me know if that is what you were looking for!

Best regards,
Andrzej
Highcharts Developer
soka
Posts: 10
Joined: Wed Oct 25, 2023 7:48 am

Re: Gantt with text-frames under years

Thanks Andrzej

What I want is a line of text items in a row between years and Names like in the attached sample.

Regards,
Søren
Attachments
Highchart Gantt.png
Highchart Gantt.png (24.51 KiB) Viewed 3308 times
michal.f
Site Moderator
Posts: 1132
Joined: Thu Aug 12, 2021 12:04 pm

Re: Gantt with text-frames under years

Hello!

You can adjust xAxis labels amout using xAxis.units property and add custom xAxis.label.formatter to achieve something this.

Demo: https://jsfiddle.net/BlackLabel/7yt5kgfh/
API: https://api.highcharts.com/gantt/xAxis.units
https://api.highcharts.com/gantt/xAxis.labels.formatter

Best regards!
Michał Filipiec
Highcharts Developer
https://blacklabel.pl/highcharts/

Return to “Highcharts Gantt”