-
Notifications
You must be signed in to change notification settings - Fork 164
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Display the last label to the x axis #37
Comments
if you create one more data without adding a xlabel for it.it shows the last label that you wanted.Your last xlabel still there but it needs one more chart data to shown.Its a bug i think. |
Hi people, yes this is a wanted behaviour, I still need to understand what's the best thing to do here. Where should the missing label go? What are your expectations? |
Hi gpbl.Thanks for your respond.According to my project, i got (n) number data and (n) number xlabel for that data.xLabel is created right after the my data appeared in my chart.But when my last data appeared in chart view,chart ends.If there is a way to expand chart view without data so i can fit my last xlabel?Thanks for your attention. |
I think it will be better if we can see all labels even if you need to add a margin. Thank you. |
@Cyphontin so in your first case how should it look the chart? Where would you put the |
Yup this is something we could support, we should just remove [this line]. I need however to double check how does it works as the the labels would span outside the chart area. |
+1 |
1 similar comment
+1 |
I've published v0.5.0 with a new option However, the label will overflow the chart width (this is the reason it is set to false as default). Since this seems a common feature request, please someone send a PR to try solving this issue 🙏🏽 |
Thank you |
The last char (here "D") is not displayed.
var labelsAsString: Array = ["L", "M", "M", "J", "V", "S", "D"]
stats.xLabelsFormatter = { (labelIndex: Int, labelValue: Float) -> String in
return labelsAsString[labelIndex]
}
Even if we use xLabelsTextAlignment = .left
The text was updated successfully, but these errors were encountered: