πŸ’₯ Beautiful, animated and highly customizable UIPageControl alternative for iOS.

Overview

PageControl

CocoaPods CocoaPods Swift 4.0

Requirements

  • iOS 9.0+
  • Xcode 7.0+

Installation

CocoaPods:

Add folowing line to Podfile and run 'pod instal'.

pod 'Sevruk-PageControl'

Or just drag and drop FoldingCell.swift file to your project

Usage with storyboard

  1. Add a new UIView to storyboard.

  2. Inherit view from PageControl.

1.1

  1. In view controller create an outlet to a view from storyboard and you're ready to go.

1.2

Here is code example that uses UIScrollView.

import UIKit
import PageControl

class ViewController: UIViewController, UIScrollViewDelegate {
    
    @IBOutlet weak var scrollView: UIScrollView!
    @IBOutlet weak var pageControl: PageControl!

    override func viewDidLoad() {
        super.viewDidLoad()
        scrollView.delegate = self
        pageControl.numberOfPages = Int(scrollView.contentSize.width / scrollView.bounds.width)
    }

    func scrollViewDidEndDecelerating(_ scrollView: UIScrollView) {
        let page = scrollView.contentOffset.x / scrollView.bounds.width
        pageControl.currentPage = page
    }
}

Usage without storyboard

  1. Create a PageControl view and add it to your view hierarchy.
let pageControl = PageControl()
addSubview(pageControl)
  1. Setup pageControl with your needs.
pageControl.numberOfPages = 5
pageControl.spacing = 14.0
pageControl.indicatorDiameter = 8.0
pageControl.currentIndicatorDiameter = 12.0
pageControl.indicatorTintColor = .darkGray
pageControl.currentIndicatorTintColor = .green
  1. And update current page when needed.
pageControl.currentPage = 1

Contributing

I'd love for you to contribute in PageControl. Feel free to submit your pull requests.

Author

Feel free to contact me via linkedin Vova Sevruk or via email: [email protected]

Licence

PageControl is released under the MIT license. See LICENSE for details.

You might also like...
This is PageControl Component for OS X. Inspired by UIPageControl and BFPageControl
This is PageControl Component for OS X. Inspired by UIPageControl and BFPageControl

NSPageControl This is PageControl Component for OS X. Inspired by UIPageControl and BFPageControl. Demo ##Installation NSPageControl supports multiple

πŸ”„ GravitySlider is a beautiful alternative to the standard UICollectionView flow layout.
πŸ”„ GravitySlider is a beautiful alternative to the standard UICollectionView flow layout.

GravitySliderFlowLayout Made by Applikey Solutions Find this project on Dribbble Table of Contents Purpose Supported OS & SDK Versions Installation Us

FlexiblePageControl - A flexible UIPageControl like Instagram.
FlexiblePageControl - A flexible UIPageControl like Instagram.

FlexiblePageControl A flexible UIPageControl like Instagram. OverView Install Carthage For Installing with Carthage, add it to your Cartfile. github "

This is a selection of custom page controls to replace UIPageControl
This is a selection of custom page controls to replace UIPageControl

PageControls This is a selection of custom page controls to replace UIPageControl, inspired by a dribbble found here. The appearance (color, size, # o

Nicely animated flat design switch alternative to UISwitch
Nicely animated flat design switch alternative to UISwitch

AIFlatSwitch A smooth, nice looking and IBDesignable flat design switch for iOS. Can be used instead of UISwitch. Inspired by Creativedash's Dribbble

πŸ”Έ A customizable alternative to UIPickerView in Swift.
πŸ”Έ A customizable alternative to UIPickerView in Swift.

PickerView PickerView is an easy to use and customize alternative to UIPickerView written in Swift. It was developed to provide a highly customizable

FYPhoto is a photo/video picker and image browser library for iOS written in pure Swift. It is feature-rich and highly customizable to match your App's requirements.
FYPhoto is a photo/video picker and image browser library for iOS written in pure Swift. It is feature-rich and highly customizable to match your App's requirements.

FYPhoto is a photo/video picker and image browser library for iOS written in pure Swift. It is feature-rich and highly customizable to match your App's requirements.

 SwiftCharts - Easy to use and highly customizable charts library for iOS
SwiftCharts - Easy to use and highly customizable charts library for iOS

SwiftCharts Easy to use and highly customizable charts library for iOS Features: Bars - plain, stacked, grouped, horizontal, vertical Scatter Lines (s

Simple and highly customizable iOS tag list view, in Swift.
Simple and highly customizable iOS tag list view, in Swift.

TagListView Simple and highly customizable iOS tag list view, in Swift. Supports Storyboard, Auto Layout, and @IBDesignable. Usage The most convenient

Easy to use and highly customizable pie charts library for iOS
Easy to use and highly customizable pie charts library for iOS

PieCharts Easy to use and highly customizable pie charts library for iOS Swift 4.2, iOS 8+ Video Features: Customizable slices Add overlays using simp

Simple and highly customizable iOS tag list view, in Swift.
Simple and highly customizable iOS tag list view, in Swift.

TagListView Simple and highly customizable iOS tag list view, in Swift. Supports Storyboard, Auto Layout, and @IBDesignable. Usage The most convenient

FLCharts: Easy to use and highly customizable charts library for iOS
FLCharts: Easy to use and highly customizable charts library for iOS

FLCharts Requirements Xcode 11 / Swift 5 iOS = 11.0 Installation FLCharts is av

Simple and highly customizable iOS tag list view, in Swift.
Simple and highly customizable iOS tag list view, in Swift.

TagListView Simple and highly customizable iOS tag list view, in Swift. Supports Storyboard, Auto Layout, and @IBDesignable. Usage The most convenient

Easy to use and highly customizable pie charts library for iOS
Easy to use and highly customizable pie charts library for iOS

PieCharts Easy to use and highly customizable pie charts library for iOS Swift 4.2, iOS 8+ Video Features: Customizable slices Add overlays using simp

Beautiful animated placeholders for showing loading of data
Beautiful animated placeholders for showing loading of data

KALoader Create breautiful animated placeholders for showing loading of data. You can change colors like you want. Swift 4 compatible. Usage To add an

Beautiful animated Alert View. Written in Swift
Beautiful animated Alert View. Written in Swift

SCLAlertView Animated Alert View written in Swift, which can be used as a UIAlertView or UIAlertController replacement. Since UIAlertView is deprecate

πŸš€  It Makes easy to track your task πŸ”₯ Beautiful & Animated UIπŸ‘¨πŸ»β€πŸ’»  . Contributions are always welcome πŸ€—
πŸš€ It Makes easy to track your task πŸ”₯ Beautiful & Animated UIπŸ‘¨πŸ»β€πŸ’» . Contributions are always welcome πŸ€—

Taskey πŸš€ What is Taskey πŸ€” ? Taskey is an application build in SwiftUI to track your task with a beautiful animations and UI . Also used core data to

Beautiful animated Login Alert View. Written in Objective-C

UIAlertView - Objective-C Animated Login Alert View written in Swift but ported to Objective-C, which can be used as a UIAlertView or UIAlertControlle

πŸš€  It Makes easy to track your task πŸ”₯ Beautiful & Animated UIπŸ‘¨πŸ»β€πŸ’»  . Contributions are always welcome πŸ€—
πŸš€ It Makes easy to track your task πŸ”₯ Beautiful & Animated UIπŸ‘¨πŸ»β€πŸ’» . Contributions are always welcome πŸ€—

Taskey πŸš€ What is Taskey πŸ€” ? Taskey is an application build in SwiftUI to track your task with a beautiful animations and UI . Also used core data to

Comments
  • Horizontal constraint issue has been solved.

    Horizontal constraint issue has been solved.

    The current version of the page control has a constraint issue that needs to provide horizontal constraint. You controlled the center property to change the position of currentIndicator, so you have to provide a frame.

    I made some of improvements to solve the constraint issue.

    opened by batuhansk 0
Owner
Sevruk Development
Sevruk Development
CHIPageControl is a set of cool animated page controls to replace boring UIPageControl.

CHIPageControl is a set of cool animated page controls to replace boring UIPageControl. We were inspired by Jardson Almeida dribbble sh

Chili Labs 3.1k Jan 4, 2023
This is PageControl Component for OS X. Inspired by UIPageControl and BFPageControl

NSPageControl This is PageControl Component for OS X. Inspired by UIPageControl and BFPageControl. Demo ##Installation NSPageControl supports multiple

Kohei Tabata 13 Jan 19, 2022
FlexiblePageControl - A flexible UIPageControl like Instagram.

FlexiblePageControl A flexible UIPageControl like Instagram. OverView Install Carthage For Installing with Carthage, add it to your Cartfile. github "

shima 732 Dec 26, 2022
This is a selection of custom page controls to replace UIPageControl

PageControls This is a selection of custom page controls to replace UIPageControl, inspired by a dribbble found here. The appearance (color, size, # o

Kyle Zaragoza 1k Jan 2, 2023
πŸ“– A simple, highly informative page view controller

TL;DR UIPageViewController done properly. ⭐️ Features Simplified data source management & enhanced delegation. Dynamically insert & remove pages. Infi

UI At Six 1.8k Jan 5, 2023
Infinite paging controller, scrolling through contents and title bar scrolls with a delay

PageController PageController is infinite paging controller, scrolling through contents and title bar scrolls with a delay. Then it provide user inter

Hirohisa Kawasaki 408 Nov 28, 2022
iPages πŸ“– Quickly implement swipable page views in iOS

iPages ?? Quickly implement swipable page views in iOS. ?? Get Started | Examples | Customize | Install | Get Started Install iPages Add iPages to you

Benjamin Sage 169 Dec 25, 2022
● β—‹ β—‹ β—‹ A nice, animated UIPageControl alternative.

Page Control Installation Usage Example import UIKit import PageControl class ViewController: UIViewController, UIScrollViewDelegate { @IBOu

Kasper Lahti 113 Sep 1, 2022
CHIPageControl is a set of cool animated page controls to replace boring UIPageControl.

CHIPageControl is a set of cool animated page controls to replace boring UIPageControl. We were inspired by Jardson Almeida dribbble sh

Chili Labs 3.1k Jan 4, 2023
UIProgressView replacement with an highly and fully customizable animated progress bar in pure Core Graphics

The YLProgressBar is an UIProgressView replacement with a highly and fully customizable animated progress bar in pure Core Graphics. It has been imple

Yannick Loriot 1.3k Jan 5, 2023