Showing
1 changed file
with
2 additions
and
39 deletions
| @@ -24,45 +24,8 @@ | @@ -24,45 +24,8 @@ | ||
| 24 | { | 24 | { |
| 25 | _inflexionPointStyle = PNScatterChartPointStyleCircle; | 25 | _inflexionPointStyle = PNScatterChartPointStyleCircle; |
| 26 | _fillColor = [UIColor grayColor]; | 26 | _fillColor = [UIColor grayColor]; |
| 27 | - _strokeColor = [UIColor blackColor]; | 27 | + _strokeColor = [UIColor clearColor]; |
| 28 | - _size = 10 ; | 28 | + _size = 3 ; |
| 29 | -} | ||
| 30 | - | ||
| 31 | -- (CAShapeLayer*) drawingPoints | ||
| 32 | -{ | ||
| 33 | - if (_inflexionPointStyle == PNScatterChartPointStyleCircle) { | ||
| 34 | - float radius = _size; | ||
| 35 | - CAShapeLayer *circle = [CAShapeLayer layer]; | ||
| 36 | - // Make a circular shape | ||
| 37 | - circle.path = [UIBezierPath bezierPathWithRoundedRect:CGRectMake(0, 0, 2.0*radius, 2.0*radius) | ||
| 38 | - cornerRadius:radius].CGPath; | ||
| 39 | - // Configure the apperence of the circle | ||
| 40 | - circle.fillColor = [_fillColor CGColor]; | ||
| 41 | - circle.strokeColor = [_strokeColor CGColor]; | ||
| 42 | - circle.lineWidth = 1; | ||
| 43 | - | ||
| 44 | - // Add to parent layer | ||
| 45 | - return circle; | ||
| 46 | - } | ||
| 47 | - else if (_inflexionPointStyle == PNScatterChartPointStyleSquare) { | ||
| 48 | - float side = _size; | ||
| 49 | - CAShapeLayer *square = [CAShapeLayer layer]; | ||
| 50 | - // Make a circular shape | ||
| 51 | - square.path = [UIBezierPath bezierPathWithRect:CGRectMake(0, 0, side, side)].CGPath ; | ||
| 52 | - // Configure the apperence of the circle | ||
| 53 | - square.fillColor = [_fillColor CGColor]; | ||
| 54 | - square.strokeColor = [_strokeColor CGColor]; | ||
| 55 | - square.lineWidth = 1; | ||
| 56 | - | ||
| 57 | - // Add to parent layer | ||
| 58 | - return square; | ||
| 59 | - | ||
| 60 | - } | ||
| 61 | - else { | ||
| 62 | - // you cann add your own scatter chart poin here | ||
| 63 | - } | ||
| 64 | - return nil ; | ||
| 65 | - | ||
| 66 | } | 29 | } |
| 67 | 30 | ||
| 68 | @end | 31 | @end |
-
Please register or login to post a comment