FlatUIColors (swift)
  • March 11, 2024

install


Make sure you have the latest version of CocoaPods (gem install cocoapods) that has Swift support. At the time of this writing, that would be 0.39.0.

Add to your Podfile:

pod ‘FlatUIColors’

And then from the shell:

$ pod install

use


There are a number of static functions defined on the struct FlatUIColors that return UIColor or NSColor objects. The return type of these functions is OSColor, which is a platform-aware typealias.

Just import and use:

import FlatUIColors

let turquoise: NSColor = FlatUIColors.turquoise()

// Optional CGFloat for setting alpha value
let emerald: UIColor = FlatUIColors.emerald(0.25)

The following is a list of all of the static color functions defined on struct FlatUIColors.

public static func turquoise() -> OSColor!
public static func greenSea() -> OSColor!
public static func mediumTurquoise() -> OSColor!
public static func lightSeaGreen() -> OSColor!
public static func emerald() -> OSColor!
public static func nephritis() -> OSColor!
public static func gossip() -> OSColor!
public static func salem() -> OSColor!
public static func peterRiver() -> OSColor!
public static func belizeHole() -> OSColor!
public static func riptide() -> OSColor!
public static func dodgerBlue() -> OSColor!
public static func amethyst() -> OSColor!
public static func wisteria() -> OSColor!
public static func lightWisteria() -> OSColor!
public static func plum() -> OSColor!
public static func wetAsphalt() -> OSColor!
public static func midnightBlue() -> OSColor!
public static func hoki() -> OSColor!
public static func ebonyClay() -> OSColor!
public static func sunflower() -> OSColor!
public static func tangerine() -> OSColor!
public static func confetti() -> OSColor!
public static func capeHoney() -> OSColor!
public static func carrot() -> OSColor!
public static func pumpkin() -> OSColor!
public static func ecstasy() -> OSColor!
public static func jaffa() -> OSColor!
public static func alizarin() -> OSColor!
public static func pomegranate() -> OSColor!
public static func monza() -> OSColor!
public static func thunderBird() -> OSColor!
public static func clouds() -> OSColor!
public static func silver() -> OSColor!
public static func gallery() -> OSColor!
public static func iron() -> OSColor!
public static func concrete() -> OSColor!
public static func asbestos() -> OSColor!
public static func pumice() -> OSColor!
public static func lynch() -> OSColor!

GitHub


View Github

#color #colorpicker #colorpickerview #colors #material-colors
YOU MIGHT ALSO LIKE...
CameraBackground

Features Both front and back camera supported. Flash modes: auto, on, off. Countdown timer. Tap to focus. Pinch to zoom. Usage  

DKCamera

Description A light weight & simple & easy camera for iOS by Swift. It uses CoreMotion framework to detect device orientation, so ...

HorizonSDK-iOS

Horizon SDK is a state of the art real-time video recording / photo shooting iOS library. Some of the features ...

LLSimpleCamera

LLSimpleCamera: A simple customizable camera - video recorder control LLSimpleCamera is a library for creating a customized camera - video ...

RSBarcodes_Swift

RSBarcodes allows you to read 1D and 2D barcodes using the metadata scanning capabilities introduced with iOS 7 and generate ...