OliverP10
Posts: 2
Joined: Thu Oct 13, 2022 9:34 pm

Text not scaling correctly

when the graph first loads
when the graph first loads
broken.jpg (110.86 KiB) Viewed 335 times
For some reason on a load of my chart, the text is not scaled correctly and doesn't fit and is too large.
I have tried calling reflow() however I only find this to work rescaling the graph to fit the container and does not fix this issue.
The only way I am able to get the text to scale properly is by manually changing my browser window size, and it seems to then fix itself.
Attachments
after I resizing chrome window
after I resizing chrome window
fixed.jpg (96.18 KiB) Viewed 335 times
kamil.m
Posts: 892
Joined: Thu May 19, 2022 1:33 pm

Re: Text not scaling correctly

Hello there,

Welcome to our forum and thank you for contacting us with your question!

It is hard to tell you what is not working and what could be done without taking look at your code. Please reproduce the issue in an online editor, such as JSFiddle so that we can take a look at the config and debug it.

Let us know once you do that.
Best regards!
Kamil Musiałowski
Highcharts Developer
OliverP10
Posts: 2
Joined: Thu Oct 13, 2022 9:34 pm

Re: Text not scaling correctly

I found the problem was that I had an animation running on the parent container of the chart that set the style({ transform: 'scale(0)' } to style({ transform: 'scale(1)' } over a period of time when first loading. For some reason, Highcharts didn't like this so I just removed the animation as a fix.
kamil.m
Posts: 892
Joined: Thu May 19, 2022 1:33 pm

Re: Text not scaling correctly

Oh yes, that could cause some issues due to Highcharts rendering to container size. But I'm glad that you have managed to fix it!

In case of any other questions, please do not hesitate to contact us!
Kamil Musiałowski
Highcharts Developer

Return to “Highcharts Stock”