Skip to content

johankasperi/SwiftHSVColorPicker

Repository files navigation

SwiftHSVColorPicker

Description

alt tag
Simple HSV Color Picker for iOS made in Swift. Includes a Hue and Saturation wheel, Brightness slider and a UIView for displaying the selected color.

Installation

Manual:

Copy the contents of "Source" to your project.

CocoaPods:

pod 'SwiftHSVColorPicker'

How to use

Add a UIView of subclass "SwiftHSVColorPicker" to your storyboard or create it programmatically:

let colorPicker = SwiftHSVColorPicker(frame: CGRectMake(10, 20, 300, 400))
self.view.addSubview(colorPicker)

After adding the Color Picker to your project, initialize your SwiftHSVColorPicker by calling:

colorPicker.setViewColor(UIColor.redColor())

This will create all the objects of the Color Picker and set they're initial value to red.

Example project

Please download and run "SwiftHSVColorPickerExample" for example usage.

License

SwiftHSVColorPicker is available under the MIT license. See the LICENSE file for more info.

Author

Johan Kasperi
@johankasperi
kspri.se

About

Simple HSV Color Picker for iOS written in Swift.

Resources

License

Stars

Watchers

Forks

Packages

No packages published