Omenien
Omenien

Reputation: 87

AChartEngine Scroll Area

Is there any way to limit the scroll area of AChartEngine? I have a graph of stats for a team where the X-axis represents time and the Y-axis represents score and it doesn't make sense to have negative for either. I'd like to make it so that the farthest that the user can scroll down and to the left would put the origin in the bottom left corner of the screen. I appreciate any assistance.

Upvotes: 0

Views: 557

Answers (1)

keshav
keshav

Reputation: 3255

Try using setPanLimits() method ..

double[] panLimits={0,10,0,50}; // [panMinimumX, panMaximumX, panMinimumY, panMaximumY] 
mRenderer2.setPanLimits(panLimits);

where mRenderer2 is XYMultipleSeriesRenderer .

Upvotes: 1

Related Questions