             }
         }
         var roundedCorners: Bool!
+        var lerpColorMode: Bool!
         var gradientRotateSpeed: CGFloat! {
             didSet {
                 invalidateGradientCache()

        progressLayer.startAngle = UtilityFunctions.Mod(startAngle, range: 360, minMax: (0,360))
        progressLayer.clockwise = clockwise
        progressLayer.roundedCorners = roundedCorners
        progressLayer.gradientRotateSpeed = gradientRotateSpeed
        progressLayer.glowAmount = UtilityFunctions.Clamp(glowAmount, minMax: (0, 1))
        progressLayer.glowMode = glowMode

                
                drawGradientWithContext(ctx, componentsArray: componentsArray)
            } else {
                
                var color: UIColor! = nil
                if colorsArray.count == 0 {
                    color = UIColor.whiteColor()
                } else if colorsArray.count == 1 {
                    color = colorsArray[0]
                } else {
                    
                    // lerpColorMode is true
                    
                    let t = CGFloat(reducedAngle) / 360
                    let steps = colorsArray.count - 1;
                    let step = 1 / CGFloat(steps);
                    for i in 1...steps {
                        let fi = CGFloat(i)
                        if (t <= fi * step || i == steps) {
                            let colorT = UtilityFunctions.InverseLerp(t, minMax: ((fi - 1) * step, fi * step))
                            color = UtilityFunctions.ColorLerp(colorT, minMax: (colorsArray[i - 1], colorsArray[i]));
                            break;
                        }
                    }
                }
                
                fillRectWithContext(ctx, color: color)
            }
            CGContextRestoreGState(ctx)
            UIGraphicsPopContext()
