• Stars
    star
    157
  • Rank 238,399 (Top 5 %)
  • Language
    Swift
  • Created over 9 years ago
  • Updated about 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

DPTheme help you set default theme color for your app.

DPTheme

DPTheme help you set default theme color for your app. Shorten the time of customization for UIControls with just one line of code.

Screenshot

![alt tag](https://raw.githubusercontent.com/dphans/DPTheme/master/Screenshot.png)

Setup

  • Import "DPTheme.swift" into your project.

  • Just one simple line of code inside 'didFinishLaunchingWithOptions':

let mainColor: UIColor = DPTheme.color(0x009688, alpha: 1.0)
let secondColor: UIColor = DPTheme.color(0xE0F2F1, alpha: 1.0)
let fontName = "Avenir"

DPTheme.setupTheme(
	mainColor,
	secondaryColor: secondColor,
	fontName: fontName,
	lightStatusBar: true)
  • (Optional) Go to your Info.plist file and set value for key 'View controller-based status bar appearance' is 'NO' for the status bar to be set to light content.

  • You can custom color for each controls, for example:

DPTheme.customizeButton(UIColor.redColor())

Contact

Email: [email protected]. Website: https://www.dphans.me.