Latest 0.0.9
License MIT
Platforms ios 11.0

Pod Version
Pod License
Pod Platform

RGTimeline is a custom timeline control written in Swift for displaying ‘events’.

Event: Anything that can be represented with a start and end date. E.g video files, calendar entries etc.

The original idea for this project came from KSTimeline, however this solution only provided support for one days worth of ‘events’. I wrote this solution from the ground up to support infinte amounts of time.

How to get started

platform :ios, '11.0'

# You need to set target when you use CocoaPods 1.0.0 or later.
target 'SampleTarget' do
  pod 'RGTimeline'
  • Download from source and build the RGTimeline framework in Release


import RGTimeline
@IBAction weak var timelineView: TimelineView!

private func render()
  //Friday, 1 June 2018 22:08:47 - Friday, 8 June 2018 22:08:47
  //Saturday, 9 June 2018 00:20:04 - Saturday, 9 June 2018 06:20:04
  //Tuesday, 26 June 2018 09:00:00 - Tuesday, 26 June 2018 09:04:36
  let firstEvent = (Date(timeIntervalSince1970: 1527890927)...Date(timeIntervalSince1970: 1528495727))
  let secondEvent = (Date(timeIntervalSince1970: 1528503604)...Date(timeIntervalSince1970: 1528525204))
  let thirdEvent = (Date(timeIntervalSince1970: 1530003600)...Date(timeIntervalSince1970: 1530003876))

  //To render in the default device timezone.
  self.timelineView.render([firstEvent, secondEvent, thirdEvent])

  //To render in a chosen timezone.
  self.timelineView.render([firstEvent, secondEvent, thirdEvent], timezone: TimeZone(identifier: "Europe/London")!)
@import RGTimeline


Endless and infinite

Render as much or as little as you’d like.

Robust and smart

Optimised for rendering large numbers of ‘events’ without taking a performance hit. Smart ‘event’ clustering also means the memory footprint is kept low.

Timezone and Daylight Savings Time support

Render ‘event’s in any timezone you choose and Daylight Savings Time transitions will be reflected.

6 levels of granularity

The timeline will render from years all the way down to seconds so ‘events’ are easy to visualise and navigating to the precise second is easy.

Fully customisable UI

Change the colours and show/hide features instantly at runtime. Also supported in Interface Builder.


The current version of RGTimeline requires:

  • Xcode 10 or later
  • Swift 4.2 or later
  • iOS 11 or later


Rhuari Glen


  • RGTimeline is available under the MIT license. See the LICENSE file.

Latest podspec

    "name": "RGTimeline",
    "version": "0.0.9",
    "summary": "A custom timeline control written in Swift",
    "swift_version": "4.2",
    "description": "A custom timeline control capable of rendering multiple 'events' that have start and end dates. E.g CCTV video files, calendar items etc",
    "homepage": "",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    "authors": {
        "Rhuari Glen": "[email protected]"
    "source": {
        "git": "",
        "tag": "0.0.9"
    "platforms": {
        "ios": "11.0"
    "source_files": "RGTimeline/**/*.{swift}"

Pin It on Pinterest

Share This