UISlider

This was killing me. I needed a custom thumb image for some sliders that displayed the currently selected range of the slider's value, not the exact number.

A quick solution to this, which I am now going to try and apply to the current build.

@IBOutlet weak var mySlider: UISlider!
@IBAction func mySliderChanged(sender: UISlider) {
var textForThumb = String()
    if sender.value <= 10 {
      textForThumb = "10"
    } else if sender.value <= 20 {
      textForThumb = "20"
    } else {
      textForThumb = "more"
    }
    let thumbImg = OWStyles.imageOfCustomThumb(frame: CGRect(x: 0, y: 0, width: mySlider.frame.height, height: mySlider.frame.height) , textForThumb: textForThumb, thumbFontSize: 20)
    mySlider.setThumbImage(thumbImg, forState: .Normal)
    
  }

That code is a bit all over the place, I mean I should not be setting the size of the thumbImg here, but I just wanted to get it working.