Toggle navigation
Toggle navigation
This project
Loading...
Sign in
iOS
/
PNChart
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
dral3x
2014-06-09 12:29:51 +0200
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
fd0472a21b93ee91086e2b0bc099aba5aa88f40e
fd0472a2
1 parent
755fc00a
Fixed wrong line width in line chart
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
5 deletions
PNChart/PNLineChart/PNLineChart.m
PNChart/PNLineChart/PNLineChart.m
View file @
fd0472a
...
...
@@ -365,16 +365,13 @@
self
.
chartPointArray
=
[
NSMutableArray
arrayWithCapacity
:
data
.
count
];
// set for point stoken
float
circle_stroke_width
=
2
.
f
;
float
line_width
=
3
.
0
f
;
for
(
PNLineChartData
*
chartData
in
data
)
{
// create as many chart line layers as there are data-lines
CAShapeLayer
*
chartLine
=
[
CAShapeLayer
layer
];
chartLine
.
lineCap
=
kCALineCapButt
;
chartLine
.
lineJoin
=
kCALineJoinMiter
;
chartLine
.
fillColor
=
[[
UIColor
whiteColor
]
CGColor
];
chartLine
.
lineWidth
=
line_w
idth
;
chartLine
.
lineWidth
=
chartData
.
lineW
idth
;
chartLine
.
strokeEnd
=
0
.
0
;
[
self
.
layer
addSublayer
:
chartLine
];
[
self
.
chartLineArray
addObject
:
chartLine
];
...
...
@@ -385,7 +382,7 @@
pointLayer
.
lineCap
=
kCALineCapRound
;
pointLayer
.
lineJoin
=
kCALineJoinBevel
;
pointLayer
.
fillColor
=
nil
;
pointLayer
.
lineWidth
=
c
ircle_stroke_w
idth
;
pointLayer
.
lineWidth
=
c
hartData
.
lineW
idth
;
[
self
.
layer
addSublayer
:
pointLayer
];
[
self
.
chartPointArray
addObject
:
pointLayer
];
...
...
Please
register
or
login
to post a comment