I have a chart with 200 StepLineSeries. For particular reasons of my layout, the delegate method toggledSelectionForSeries is not called when the right series whenever I tap in one of them. Thus, I want to manually select and deselect the series.
I have an algorith that based on the location of the user's touch determines which series correspond to that datapoint. However, when it comes to apply the selectedStyle, nothings happens. When I create my series I define the style and selectedStyle properties with the right values. When I detect the touch, changing the selected property of the series to YES does nothing. I have also tried by creating a new SChartLineSeriesStyle, setting that object as the style property of the series and calling [ShinobiChart redrawChart], but again nothing changes.
I have to say that I have the selectionMode of my series set to SChartSelectionNone. Does it mean that series can never be selected?
As I said, setting the mode to SChartSelectionSeries makes the delegate select the wrong series. My workaround was to keep track of the selectedSeries that I calculate and have this as the implementation of the delegate method:
- (void)sChart:(ShinobiChart *)chart toggledSelectionForSeries:(SChartSeries *)series nearPoint:(SChartDataPoint *)dataPoint atPixelCoordinate:(CGPoint)pixelPoint
series.selected = NO;
self.selectedSeries.selected = YES;
But for some reason that introduces a very large lag between the tapping and actually the changing in the selected series style.
Is there any way to accomplish what I am trying to do?