An open API service indexing awesome lists of open source software.

https://github.com/maximbilan/swiftthicknesspicker

iOS thickness picker
https://github.com/maximbilan/swiftthicknesspicker

ios ios-thickness-picker picker pickerview ui ui-components ui-design ui-kit uiview

Last synced: 12 months ago
JSON representation

iOS thickness picker

Awesome Lists containing this project

README

          

## Swift Thickness Picker

[![Version](https://img.shields.io/cocoapods/v/SwiftThicknessPicker.svg?style=flat)](http://cocoadocs.org/docsets/SwiftThicknessPicker)
[![License](https://img.shields.io/cocoapods/l/SwiftThicknessPicker.svg?style=flat)](http://cocoadocs.org/docsets/SwiftThicknessPicker)
[![Platform](https://img.shields.io/cocoapods/p/SwiftThicknessPicker.svg?style=flat)](http://cocoadocs.org/docsets/SwiftThicknessPicker)
[![CocoaPods](https://img.shields.io/cocoapods/dt/SwiftThicknessPicker.svg)](https://cocoapods.org/pods/SwiftThicknessPicker)
[![CocoaPods](https://img.shields.io/cocoapods/dm/SwiftThicknessPicker.svg)](https://cocoapods.org/pods/SwiftThicknessPicker)

A simple iOS thickness picker.

Supports two modes: vertical and horizontal.

![alt tag](https://raw.github.com/maximbilan/SwiftThicknessPicker/master/img/img1.png)

## Installation

CocoaPods:


pod 'SwiftThicknessPicker'

Manual:


Copy SwiftThicknessPicker.swift to your project.

## Using

You can create from Storyboard or XIB. Or create manually:


let picker = SwiftThicknessPicker()

For handling changing of values you should implement protocol SwiftThicknessPickerDelegate:

picker.delegate = self

func valueChanged(value: Int)
}

Direction:


picker.direction = SwiftThicknessPicker.PickerDirection.Vertical // Vertical, Horizontal

Also, you can change current value, the maximum value or minimum value, for example:


picker.currentValue = 0
picker.maxValue = 30
picker.minValue = 1

And other settings:

labelFontColor // A font color of the moving label
labelBackgroundColor // A background color of the moving label
labelFont // A font of the moving label

## License

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