Hi,
I have used bar chart. And currently set the following properties of it:
self.barChart?.doubleTapToZoomEnabled = false
self.barChart?.pinchZoomEnabled = false
barChart.dragEnabled = false
But still the zoom is happening. One of the reason that I have not tried out might be disable the individual axis scaling. Can some one please provide me the code for that or any other solution that will work ?
Are you saying if you turn off pinchZoomEnabled, pinch zoom still work? I suspect it. Please just search the code how it's enforced and see what you have to disable.
e.g.
if _data !== nil &&
(_pinchZoomEnabled || _scaleXEnabled || _scaleYEnabled)
{
it's OR op, so only disable one is not enough.
you may forgot to use this:
Objective-c:
self.chartView.scaleXEnabled = NO;
self.chartView.scaleYEnabled = NO;
swift:
self.barChart?.scaleYEnabled = false
self.barChart?.scaleXEnabled = false
Most helpful comment
you may forgot to use this:
Objective-c:
swift: