Reputation: 577
I need disable some elements from my chart.
I used the iOS-charts library in (Swift 2), however I can't understand how to disable the following:
Hide right and left numbers
Hide description color square
Upvotes: 37
Views: 20356
Reputation: 598
For only hide the top one:
graphCell.lineChartView.leftAxis.drawTopYLabelEntryEnabled = false
Upvotes: 0
Reputation: 3232
self.chartView.drawEntryLabelsEnabled = false
This will hide the label from PieChart
and shows only value. Also shows legend with label texts.
Upvotes: 4
Reputation: 2470
self.chartView.xAxis.drawGridLinesEnabled = false
self.chartView.leftAxis.drawLabelsEnabled = false
self.chartView.legend.enabled = false
will do the job
Upvotes: 112