Jawbone / JBChartView

iOS-based charting library for both line and bar graphs.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

X,Y position of dot in LineChart

ZuzanaBenicko opened this issue · comments

Iam sorry this is more question than issue. Iam using your LineChartView but I need to alter the dot which is in it for another dot picture(and also get there vertical line in this position) Is there a way how to get the x and y position of dot in LineChart?

The dot positions (ie. CGPoint) are not exposed through any public interface.

What exactly are you trying to do? Any diagrams or code would help as well.

What I would like to do is alter dot for something like this.

linechart

It's is not possible to get an (x,y) position of a dot while scrubbing.

You could presumably create a delegate callback (in JBLineChartView):

- (UIView *)didSelectDotAtIndex:(NSUInteger)lineIndex horizontalIndex:(NSUInteger)horizontalIndex;

Take a peak at touchesBeganOrMovedWithTouches to see how we do this for line selections.

I would suggest forking the library and making the appropriate changes to suit your needs, but at this moment, we don't plan on integrating dot selection callbacks.

Closing issue.