RangeControl is a UIControl element that allows to select control range from min to max values.
You can setup RangeControl from code or from storyboard. It also allows you to add custom view to the background.
let imageView = UIImageView(image: UIImage(named: "testImage"))
imageView.contentMode = .scaleAspectFill
imageView.translatesAutoresizingMaskIntoConstraints = false
imageView.clipsToBounds = true
rangeControl.backgroundView.addArrangedSubview(imageView)
You can add block to listen for values update:
rangeControl.onRangeValueChanged = { (low,up) in
print("Low: \(low) up: \(up)")
}
The demo project is included here RangeControlExample.
- iOS 10.0+
- Xcode 10.1+
- Swift 4.2+
CocoaPods is a dependency manager for Cocoa projects. For usage and installation instructions, visit their website. To integrate Alamofire into your Xcode project using CocoaPods, specify it in your Podfile
:
pod 'RangeControl'
- Alexey Ledovskiy - Initial work - RangeControl
Any amount you can donate today to support the project would be greatly appreciated.
This project is licensed under the MIT License - see the LICENSE file for details