Set different default range and axis range for an axis


#1

Hi there,

I’m trying to effectively set a larger bounds that a user can’t zoom / pan past using the defaultRange and allowPanningOutOfDefaultRange = false, but still have the axis start in a different smaller range. Is this possible? I’ve tried the following but it seems to always initalize in the default range:

SChartDateTimeAxis *xAxis = [[SChartDateTimeAxisalloc] init];

xAxis.defaultRange = [[SChartDateRangealloc] initWithDateMinimum:[NSDate dateWithTimeIntervalSince1970:CHART_DATE_RANGE_MIN_UNIXTIME] andDateMaximum:[NSDatedateWithTimeInterval:TIME_ONE_MINUTEsinceDate:[NSDatedate]]];

[xAxis setRangeWithMinimum:startDate andMaximum:endDate];

Thanks for your time in advance!