mySpecialCharts
Posts: 1
Joined: Tue Jun 28, 2022 10:13 pm

seriesType 'flags' overlapping

I have been trying to ensure my Flag series do not overlap each other.

Found this post and used this drawPoints function:
https://github.com/highcharts/highchart ... -154013703

It is working, somewhat...

However, when I click on the LegendItems, the chart re-renders, and the Overlap happens seemingly inconsistently, since new series are now being shown on the chart.

I've already called the redraw function for LegendItemClick:
plotOptions: {
series: {
events: {
legendItemClick: function (event) {
this.redraw()
},
}
}
},
.....

The FLAG series are still overlapping when some legendItem series are clicked. I tried to debug it and it seems like the LegendItemClick does not have the latest values for the series, hence passing non-updated { comparePoint.graphic.translateY } position, making collision return false (when there is supposed to be colliding points).

I am only having issues identifying the collision when the points are aligned vertically on top of each other.

Can someone please help? Thanks.
kamil.m
Posts: 892
Joined: Thu May 19, 2022 1:33 pm

Re: seriesType 'flags' overlapping

Hi 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 a look at your code. Could you reproduce the issue in an online editor (i.e JSFiddle) that I could work on?

Waiting for your reply,
Regards!
Kamil Musiałowski
Highcharts Developer

Return to “Highcharts Usage”