iPhone Core-plot: Chart Zoom In Zoom out, Y axis Bigger, Y axis Smaller

后端 未结 1 1878
南笙
南笙 2021-01-19 21:29

I am now using Core-plot for iPhone chart Development. But it has some requirement i can not reach.

I am now using CorePlot 0.4, example code

相关标签:
1条回答
  • 2021-01-19 22:13

    I see several questions here:

    1. Y-axis scale: Try the CPTAxisLabelingPolicyAutomatic labeling policy on your y-axis. If that doesn't give you enough control, use a different labeling policy and use a plot space delegate to adjust the labeling parameters as the user zooms in and out.

    2. Disappearing x-axis: Make it a "floating" axis. For example,

      x.axisConstraints = [CPTConstraints constraintWithLowerOffset:0.0];
      
    3. Maximum zoom level: Use the globalXRange and globalYRange plot space properties. If you need more control, you can use a plot space delegate.

    4. Scroll bars: This isn't directly supported. You could use a plot space delegate to update the scroll bar position.

    0 讨论(0)
提交回复
热议问题