update name

This commit is contained in:
Xinlei(Ryan) Pan 2020-01-16 16:30:05 -05:00
parent cb89795b4c
commit 36cbccd39c
2 changed files with 3 additions and 3 deletions

View File

@ -135,7 +135,7 @@ open class DoughnutChart: View {
let clockwise = true
let value: CGFloat = chartModel.percent
let gap: CGFloat = spaceReuired() ? lineGap() : 0.0
let gap: CGFloat = spaceRequired() ? lineGap() : 0.0
let startAngle = ((prevPercent / 100.0) * 2 * .pi) - (0.5 * .pi)
let endAngle = ((value / 100.0) * 2 * .pi) + startAngle - gap
let circlePath = UIBezierPath(arcCenter: arcCenter,
@ -168,7 +168,7 @@ open class DoughnutChart: View {
return doughnutChartModel?.sections.count == 1 ? 0.0 : 0.05
}
func spaceReuired() -> Bool {
func spaceRequired() -> Bool {
return doughnutChartModel?.spaceRequired ?? true
}

View File

@ -50,7 +50,7 @@ import Foundation
centerY.isActive = true
colorLablesStack.leadingAnchor.constraint(equalTo: doughnutChart.trailingAnchor, constant: PaddingThree).isActive = true
colorLablesStack.backgroundColor = UIColor.clear
colorLablesStack.backgroundColor = .clear
}
open override func updateView(_ size: CGFloat) {