7
7
// Copyright (c) 2014 Sam Spencer.
8
8
//
9
9
10
-
11
- #if __has_feature(objc_modules)
12
- // We recommend enabling Objective-C Modules in your project Build Settings for numerous benefits over regular #imports
13
- @import Foundation;
14
- @import UIKit;
15
- @import CoreGraphics;
16
- #else
17
- #import < Foundation/Foundation.h>
18
- #import < UIKit/UIKit.h>
19
- #import < CoreGraphics/CoreGraphics.h>
20
- #endif
10
+ @import Foundation;
11
+ @import UIKit;
12
+ @import CoreGraphics;
21
13
22
14
#import " BEMAverageLine.h"
23
15
@@ -50,51 +42,39 @@ typedef NS_ENUM(NSUInteger, BEMLineGradientDirection) {
50
42
51
43
// ----- POINTS -----//
52
44
53
- // / The previous point. Necessary for Bezier curve
54
- @property (assign , nonatomic ) CGPoint P0;
55
-
56
- // / The starting point of the line
57
- @property (assign , nonatomic ) CGPoint P1;
58
-
59
- // / The ending point of the line
60
- @property (assign , nonatomic ) CGPoint P2;
61
-
62
- // / The next point. Necessary for Bezier curve
63
- @property (assign , nonatomic ) CGPoint P3;
64
-
65
45
// / All of the Y-axis values for the points
66
- @property (nonatomic ) NSArray *arrayOfPoints;
46
+ @property (strong , nonatomic ) NSArray *arrayOfPoints;
67
47
68
48
// / All of the X-Axis coordinates used to draw vertical lines through
69
- @property (nonatomic ) NSArray *arrayOfVerticalRefrenceLinePoints;
49
+ @property (strong , nonatomic ) NSArray *arrayOfVerticalRefrenceLinePoints;
70
50
71
51
// / The value used to offset the fringe vertical reference lines when the x-axis labels are on the edge
72
52
@property (assign , nonatomic ) CGFloat verticalReferenceHorizontalFringeNegation;
73
53
74
54
// / All of the Y-Axis coordinates used to draw horizontal lines through
75
- @property (nonatomic ) NSArray *arrayOfHorizontalRefrenceLinePoints;
55
+ @property (strong , nonatomic ) NSArray *arrayOfHorizontalRefrenceLinePoints;
76
56
77
57
// / All of the point values
78
- @property (nonatomic ) NSArray *arrayOfValues;
58
+ @property (strong , nonatomic ) NSArray *arrayOfValues;
79
59
80
60
/* * Draw thin, translucent, reference lines using the provided X-Axis and Y-Axis coordinates.
81
61
@see Use \p arrayOfVerticalRefrenceLinePoints to specify vertical reference lines' positions. Use \p arrayOfHorizontalRefrenceLinePoints to specify horizontal reference lines' positions. */
82
- @property (nonatomic ) BOOL enableRefrenceLines;
62
+ @property (assign , nonatomic ) BOOL enableRefrenceLines;
83
63
84
64
/* * Draw a thin, translucent, frame on the edge of the graph to separate it from the labels on the X-Axis and the Y-Axis. */
85
- @property (nonatomic ) BOOL enableRefrenceFrame;
65
+ @property (assign , nonatomic ) BOOL enableRefrenceFrame;
86
66
87
67
/* * If reference frames are enabled, this will enable/disable specific borders. Default: YES */
88
- @property (nonatomic ) BOOL enableLeftReferenceFrameLine;
68
+ @property (assign , nonatomic ) BOOL enableLeftReferenceFrameLine;
89
69
90
70
/* * If reference frames are enabled, this will enable/disable specific borders. Default: YES */
91
- @property (nonatomic ) BOOL enableBottomReferenceFrameLine;
71
+ @property (assign , nonatomic ) BOOL enableBottomReferenceFrameLine;
92
72
93
73
/* * If reference frames are enabled, this will enable/disable specific borders. Default: NO */
94
- @property (nonatomic ) BOOL enableRightReferenceFrameLine;
74
+ @property (assign , nonatomic ) BOOL enableRightReferenceFrameLine;
95
75
96
76
/* * If reference frames are enabled, this will enable/disable specific borders. Default: NO */
97
- @property (nonatomic ) BOOL enableTopReferenceFrameLine;
77
+ @property (assign , nonatomic ) BOOL enableTopReferenceFrameLine;
98
78
99
79
/* * Dash pattern for the references line on the X axis */
100
80
@property (nonatomic , strong ) NSArray *lineDashPatternForReferenceXAxisLines;
@@ -103,10 +83,10 @@ typedef NS_ENUM(NSUInteger, BEMLineGradientDirection) {
103
83
@property (nonatomic , strong ) NSArray *lineDashPatternForReferenceYAxisLines;
104
84
105
85
/* * If a null value is present, interpolation would draw a best fit line through the null point bound by its surrounding points. Default: YES */
106
- @property (nonatomic ) BOOL interpolateNullValues;
86
+ @property (assign , nonatomic ) BOOL interpolateNullValues;
107
87
108
88
/* * Draws everything but the main line on the graph; correlates to the \p displayDotsOnly property. Default: NO */
109
- @property (nonatomic ) BOOL disableMainLine;
89
+ @property (assign , nonatomic ) BOOL disableMainLine;
110
90
111
91
112
92
@@ -141,20 +121,20 @@ typedef NS_ENUM(NSUInteger, BEMLineGradientDirection) {
141
121
// ----- ALPHA -----//
142
122
143
123
// / The line alpha
144
- @property (nonatomic ) float lineAlpha;
124
+ @property (assign , nonatomic ) float lineAlpha;
145
125
146
126
// / The alpha value of the area above the line, inside of its superview
147
- @property (nonatomic ) float topAlpha;
127
+ @property (assign , nonatomic ) float topAlpha;
148
128
149
129
// / The alpha value of the area below the line, inside of its superview
150
- @property (nonatomic ) float bottomAlpha;
130
+ @property (assign , nonatomic ) float bottomAlpha;
151
131
152
132
153
133
154
134
// ----- SIZE -----//
155
135
156
136
// / The width of the line
157
- @property (nonatomic ) float lineWidth;
137
+ @property (assign , nonatomic ) float lineWidth;
158
138
159
139
// / The width of a reference line
160
140
@property (nonatomic ) float referenceLineWidth;
@@ -164,17 +144,17 @@ typedef NS_ENUM(NSUInteger, BEMLineGradientDirection) {
164
144
// ----- BEZIER CURVE -----//
165
145
166
146
// / The line is drawn with smooth curves rather than straight lines when set to YES.
167
- @property (nonatomic ) BOOL bezierCurveIsEnabled;
147
+ @property (assign , nonatomic ) BOOL bezierCurveIsEnabled;
168
148
169
149
170
150
171
151
// ----- ANIMATION -----//
172
152
173
153
// / The entrance animation period in seconds.
174
- @property (nonatomic ) CGFloat animationTime;
154
+ @property (assign , nonatomic ) CGFloat animationTime;
175
155
176
156
// / The type of entrance animation.
177
- @property (nonatomic ) BEMLineAnimation animationType;
157
+ @property (assign , nonatomic ) BEMLineAnimation animationType;
178
158
179
159
180
160
@@ -184,7 +164,7 @@ typedef NS_ENUM(NSUInteger, BEMLineGradientDirection) {
184
164
@property (strong , nonatomic ) BEMAverageLine *averageLine;
185
165
186
166
// / The average line's y-value translated into the coordinate system
187
- @property (nonatomic ) CGFloat averageLineYCoordinate;
167
+ @property (assign , nonatomic ) CGFloat averageLineYCoordinate;
188
168
189
169
190
170
0 commit comments