Advertisement
Guest User

Untitled

a guest
Oct 10th, 2019
113
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.93 KB | None | 0 0
  1. //
  2. // UIColorCustom.swift
  3. // DemoProj
  4. //
  5. // Created by Ahsan Parekh on 16/09/2019.
  6. // Copyright © 2019 Avanza. All rights reserved.
  7. //
  8.  
  9. //
  10. // Extension_Color.swift
  11. // AmbitBox
  12. //
  13. // Created by Avanza on 3/18/19.
  14. // Copyright © 2019 AvanzaSolutions. All rights reserved.
  15. //
  16.  
  17. import Foundation
  18. import UIKit
  19.  
  20. extension UIColor {
  21. convenience init(rgb: UInt) {
  22. self.init(
  23. red: CGFloat((rgb & 0xFF0000) >> 16) / 255.0,
  24. green: CGFloat((rgb & 0x00FF00) >> 8) / 255.0,
  25. blue: CGFloat(rgb & 0x0000FF) / 255.0,
  26. alpha: CGFloat(1.0)
  27. )
  28. }
  29.  
  30. struct Palette{
  31. static let black = UIColor.init(rgb: UInt(0x000000))
  32. static let white = UIColor.init(rgb: UInt(0xFFFFFF))
  33. static let titanWhite = UIColor.init(rgb: UInt(0xe5e5ff))
  34. static let brightTurquoise = UIColor.init(rgb: UInt(0x0DE3FA))
  35. static let jordyBlue = UIColor.init(rgb: UInt(0x96C0F5))
  36. static let blueRibbon = UIColor.init(rgb: UInt(0x0248FF))
  37. static let blueHaze = UIColor.init(rgb: UInt(0xC5CDDF))
  38. static let royalBlue = UIColor.init(rgb: UInt(0x2680EB))
  39. static let toryBlue = UIColor.init(rgb: UInt(0x135CA5))
  40. static let darkBlue = UIColor.init(rgb: UInt(0x1000a4))
  41. static let pictonBlue = UIColor.init(rgb: UInt(0x3488EC))
  42. static let shamrock = UIColor.init(rgb: UInt(0x35DCA4))
  43. static let periwinkle = UIColor.init(rgb: UInt(0xC9D2FF))
  44. static let nepal = UIColor.init(rgb: UInt(0x8F9FC2))
  45. static let red = UIColor.init(rgb: UInt(0xFF0000))
  46. static let rose = UIColor.init(rgb: UInt(0xFF0180))
  47. static let abbey = UIColor.init(rgb: UInt(0x4D4F56))
  48. static let purpleHeart = UIColor.init(rgb: UInt(0x462EDB))
  49. static let geyser = UIColor.init(rgb: UInt(0xCAD2DE))
  50. static let whisper = UIColor.init(rgb: UInt(0xFBFBFD))
  51. static let botticelli = UIColor.init(rgb: UInt(0xD9E2EF))
  52. static let alabaster = UIColor.init(rgb: UInt(0xFCFCFC))
  53. static let ghost = UIColor.init(rgb: UInt(0xC7C9D5))
  54. static let baliHai = UIColor.init(rgb: UInt(0x859FAF))
  55. static let energyYellow = UIColor.init(rgb: UInt(0xF8DB4D))
  56. static let blackRussian = UIColor.init(rgb: UInt(0x00001E))
  57. static let wildBlueYonder = UIColor.init(rgb: UInt(0x8997BB))
  58. static let mirage = UIColor.init(rgb: UInt(0x191E2D))
  59. static let rockBlue = UIColor.init(rgb: UInt(0xA3AEC9))
  60. static let darkGray = UIColor.darkGray
  61. static let athensGray = UIColor.init(rgb: UInt(0xF6F6F9))
  62. static let cornflowerBlue = UIColor.init(rgb: UInt(0x4B8EE7))
  63. static let spindle = UIColor.init(rgb: UInt(0xBFD3EF))
  64. }
  65. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement