CHIPageControl is a set of cool animated page controls to replace boring UIPageControl.
- iOS 8.0+
- Xcode 8+
- Swift 3
Just add the
CHIPageControl folder to your project.
use CocoaPods with Podfile:
pod 'CHIPageControl', '~> 0.1.3' # individual page control pod 'CHIPageControl/Aji' pod 'CHIPageControl/Aleppo' pod 'CHIPageControl/Chimayo' pod 'CHIPageControl/Fresno' pod 'CHIPageControl/Jalapeno' pod 'CHIPageControl/Jaloro' pod 'CHIPageControl/Paprika' pod 'CHIPageControl/Puya'
use Carthage with Cartfile
github "ChiliLabs/CHIPageControl" ~> 0.1.3
Swift Package Manager
The Swift Package Manager is a tool for managing the distribution of Swift code.
Add the following to your
dependencies: [ .package(url: "https://github.com/ChiliLabs/CHIPageControl.git", .branch("master")) ]
And then build your project
$ swift build
Just drop UIView and set its class to be one of CHIPageControls.
let pageControl = CHIPageControlAji(frame: CGRect(x: 0, y:0, width: 100, height: 20)) pageControl.numberOfPages = 4 pageControl.radius = 4 pageControl.tintColor = .red pageControl.currentPageTintColor = .green pageControl.padding = 6
Adding multiple tintColors
// The size of the array needs to match the numberOfPages or it will throw an fatal error pageControl.tintColors = [UIColor.black, UIColor.yellow, UIColor.black, UIColor.black] // or // If it is the first one, it will fill all colors with the selected tintColor and then replace the colors with the desired one pageControl.insertTintColor(UIColor.yellow, position: 1)
//update dynamically pageControl.progress = 0.5 //set progress with animation pageControl.set(progress: 2, animated: true)
You can hear touch events in any of the page indicators.
pageControl.enableTouchEvents = true
CHIBasePageControlDelegate to catch touch events.
func didTouch(pager: CHIBasePageControl, index: Int)
What is Copy-On-Write
Copy-On-Write (COW) is a strategy used in computer programming and operating systems to optimize the performance and efficiency of memory...
Mobile App Development Best Practices – 11.12
Large photos in SwiftUI, Mutation Testing, Processing Payments in Firebase and more!
SDKs for which Apple will require a signature have been published
Apple has already listed SDKs commonly used in apps in the App Store that, from spring 2024, you will be...
Discover the Journaling Suggestions API
Journaling Suggestions is a visual picker interface for iPhone applications. It displays personal events that are happening in a person’s...
Tusky – An Android client for the microblogging server Mastodon
Tusky is a beautiful Android client for Mastodon. Mastodon is an ActivityPub federated social network. That means no single entity controls...
Swift 30 Projects: 30 mini Swift Apps for self-study
This repo is updated with Swift 5 and compatible with iPhone X: Simple UIKit components UIScrollView, UITableView, UICollectionView CAAnimations and...