I'm having a little bit of trouble with the x-axis tick/labels on an edge-to-edge chart. Is there a way to do one of the following on a chart that allows for panning? Or maybe something else entirely that may help with this use case?
Hi Cory,
Greetings from Syncfusion. We have checked the reported issue regarding when the edgeLabelPlacement is hide the unclipped axis label also gets hidden and ensured the issue gets reproduced at our end. In previous we have considered the first and last labels are edge labels and hide them, now we will consider the clip area and fix based on this. We consider this a bug, and it will be included in our upcoming weekly patch releases on 19th July 2022. We appreciate your patience until then.
Regards,
Yuvaraj.
Hi there,
This is great news, thank you! I'm very excited! :)
Thanks again,
Cory
Hi Cory,
Thanks for the update, we will let you know once the release got roll out. We appreciate your patience until then.
Regards,
Yuvaraj.
Hi Cory,
Here is the feedback for the bug fix, you can track the status of the bug here. Please find the link below.
Feedback: https://www.syncfusion.com/feedback/36368/need-to-hide-edge-axis-label-based-on-the-clip-area
Regards,
Yuvaraj.
Hi Cory,
We regret the inconvenience. When our development team moves forward to fix the issue, this is the behavior i.e if the edge label placement is set as hide, then by default, the first and last label will be hidden whether the labels move out of the bounds or not and this can’t be changed. When the plot offset is applied, it will be added at both the edges of the axis and unable to add at one side alone. And if you wish to move the axis to the opposite position, you can make use of the opposedPosition property in the axis.
And in your case the last label in the x-axis moves out of the layout, in this case, you can use the shift option in the edgeLabelPlacement, this will shift the first and last labels.
If the labels get intersect, then you can position the axis label smartly using the labelIntersectAction feature. More information can be found below
https://help.syncfusion.com/flutter/cartesian-charts/axis-customization#smart-axis-labels
Also, if you wish to rotate the axis labels by default, then you can make use labelRotation property and set this to 90, this will avoid moving the last label out of the layout.
https://help.syncfusion.com/flutter/cartesian-charts/axis-customization#axis-label-rotation
Hope this helps.
Thanks,
Yuvaraj.
Hey Yuvaraj,
I appreciate the assistance!
But, unfortunately none of these configuration options help with the edge-to-edge chart use case, because they do not change the horizontal position of the end axis tick and label.
To move things along for our company, I implemented a draft feature:
https://github.com/CoryADavis/flutter-widgets/compare/master...CoryADavis:flutter-widgets:Introduce-edgeLabelPlacement.hideEnd
Essentially, just a new enum option for edgeLabelPlacement; whether the labels move out of bounds or not, it only hides the end label instead of the start and end label. The example now looks like this using edgeLabelPlacement.hideEnd: https://imgur.com/gtSejDb, which works for us.
Thanks,
Cory
Hi Cory,
We have considered this as a feature request, and we have logged the feedback for this. We will implement this and include it in any of our upcoming releases. We have attached the feedback below for your reference, here you can track the status of the feature.
Feedback: https://www.syncfusion.com/feedback/36567
Regards,
Yuvaraj.