Latest 1.0.3
Homepage https://github.com/dan12411/ScrollPage
License MIT
Platforms ios 8.0
Frameworks Foundation, UIKit
Authors

License
Platform

ScrollPage is a custom control which is mixture of UIScrollView contains Container Views and Scrollable Tab Bar.

Demo:

(Without Customization)

demo
demo

Installation

CocoaPods

ScrollPage is available through CocoaPods. !! Swift only !!

To install add the following line to your Podfile:

pod 'ScrollPage'

How to use

//Add the title bar elements as an Array of String
swipeableView.titleBarDataSource = titleBarDataSource //Array of Button Titles like ["Movies", "Society", "Health"]

//Assign your viewcontroller as delegate to load the Viewcontroller
swipeableView.delegate = self

//Set the View Frame (64.0 is 44.0(NavigationBar Height) + 20.0(StatusBar Height))
swipeableView.viewFrame = CGRect(x: 0.0, y: 64.0, width: UIScreen.mainScreen().bounds.width, height: UIScreen.mainScreen().bounds.height-64.0)

//Then add the view controller on the current view.
self.addChildViewController(swipeableView)
self.view.addSubview(swipeableView.view)
swipeableView.didMoveToParentViewController(self)

Customization

swipeableView.buttonWidth = 60.0

Similarly Height of selectionBar can be changed using

swipeableView.selectionBarHeight = 2.0 //For thin line

We can also change the height of the segmentBar, use the below line of code:

swipeableView.segementBarHeight = 50.0 //Default is 44.0

Padding in the button can be customised using:


swipeableView.buttonPadding = 10.0 //Default is 8.0

Latest podspec

{
    "name": "ScrollPage",
    "version": "1.0.3",
    "summary": "ScrollPage is a custom control which is mixture of UIScrollView contains Container Views and Scrollable Tab Bar.",
    "description": "ScrollPage is a custom control which is mixture of UIScrollView contains Container Views and Scrollable Tab Bar. Different from SMSwipeableTabView which used PageViewController. Use UIScrollView to get more flexibility.",
    "homepage": "https://github.com/dan12411/ScrollPage",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "TeCheng Hung": "[email protected]"
    },
    "social_media_url": "https://twitter.com/techenghung",
    "platforms": {
        "ios": "8.0"
    },
    "source": {
        "git": "https://github.com/dan12411/ScrollPage.git",
        "tag": "1.0.3"
    },
    "source_files": [
        "ScrollPage",
        "ScrollPage/**/*.{h,m,swift}"
    ],
    "frameworks": [
        "Foundation",
        "UIKit"
    ],
    "pod_target_xcconfig": {
        "SWIFT_VERSION": "3.0"
    },
    "pushed_with_swift_version": "3.0"
}

Pin It on Pinterest

Share This