crash fix
This commit is contained in:
parent
0c7726bcc3
commit
a76fb75200
@ -176,7 +176,7 @@ open class DoughnutChart: View {
|
||||
labelContainer.layoutIfNeeded()
|
||||
let radius = sizeObject.getValueBasedOnApplicationWidth()/2 - lineWidth()
|
||||
let labelheight = labelContainer.frame.height/2
|
||||
let padding = sizeObject.getValueBasedOnApplicationWidth()/2 - sqrt(pow(radius, 2) - pow(labelheight, 2))
|
||||
let padding = sizeObject.getValueBasedOnApplicationWidth()/2 - sqrt(abs(pow(radius, 2) - pow(labelheight, 2)))
|
||||
|
||||
labelContainerLeftConstraint?.constant = padding
|
||||
labelContainerRightConstraint?.constant = padding
|
||||
|
||||
Loading…
Reference in New Issue
Block a user