ios - Core Plot - X-Axis moving position when plotting less points -


i have strange problem x-axis moves down plot area when i'm plotting less points. graph has 2 lines plotted - 1 previous year , 1 current year values. original graph plotted 12 points both lines, regardless of month in , works fine. have changed app current year line plots points upto current month. e.g. in may plot 5 points. when x-axis moves down plot area detached y-axis , labels hidden - see screenshots :

graph 12 points graph 5 points

why reducing number of plot points change x-axis position? i'm using core plot 1.1 (static library) , xcode 4.6.2.

the yrange of plot space changed point x-axis crosses y-axis close bottom edge of graph. have 2 options:

  • ensure yrange puts crossing point (the "orthogonal coordinate") far enough edge labels , title remain visible.

  • use axisconstraints position axis fixed distance edge of graph. let crossing point float along y-axis.


Comments

Popular posts from this blog

linux - xterm copying to CLIPBOARD using copy-selection causes automatic updating of CLIPBOARD upon mouse selection -

c++ - qgraphicsview horizontal scrolling always has a vertical delta -