I have a iPhone app with a CorePlot graph. I would like the user to be able to zoom in and out of the graph similar to the default functionality except for one thing:
- When the user pinches horizontally -> zoom the x-axis.
- Vertically -> zoom the y-axis.
- Diagonally -> zoom both axes.
How can I implement this functionality? Any suggestions would be appreciated.
As Felix Khazin shows in in his answer.
The code is in his answer.
To actually manage the vertica/diagonal/horizontal gestures.
1 Create UIPinchGestureRecognizer
EDIT
2 Implement handlePinchGesture method.