I am using core plot 1.0 in my iphone app. All works fine, graphs are drawing perfectly, But I am facing a weird problem that All the controls on graph page(CPTPGraphHostingView
References for this answer:
I came to know that the whole CPTPGraphHostingView is inverted upside down to support both Mac OS and iOS. This is by design and is not a bug.
So the solution from the given links is that:
CPTPGraphHostingView
(for adding graph) and the other of type UIView
(for adding any other ui controls, backgrounds etc). You can modify the type of View by modifying Class field
under the heading Class Identity
in View Identity tab
of File's Owner window
.UPDATE: If you add CPTPGraphHostinView to interface, no other components will be visible, for that you'll have to set theme, and fill of CPTXYGraph to nil. Ie add following lines after you initialize your CPTXYGraph:
CPTTheme *theme = nil;
[barChart applyTheme:theme]; // barChart is my CPTXYGraph
barChart.fill = nil;
barChart.plotAreaFrame.fill = nil;
NOTE:: Add CPTPGraphHostingView such that it is child of top level UIView, and other components are in top level UIView, and CPTPGraphHostingView is above all other components.
Try self.view = (CPTPGraphHostingView *)view