Skip to content

Convenience method for creating autoreleased color using RGBA hex string.

License

Notifications You must be signed in to change notification settings

niaorenhuaduo/UIColor-Hex-Swift

 
 

Repository files navigation

UIColor+Hex, now Swift.

Convenience method for creating autoreleased color using RGBA hex string.

var strokeColor = UIColor(rgba: "#ffcc00").CGColor // Solid color

var fillColor = UIColor(rgba: "#ffcc00dd").CGColor // Color with alpha

var backgroundColor = UIColor(rgba: "#FFF") // Supports shorthand 3 character representation

var menuTextColor = UIColor(rgba: "#013E") // Supports shorthand 4 character representation (with alpha)

See more in RSBarcodes_Swift and objc version

About

Convenience method for creating autoreleased color using RGBA hex string.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Swift 79.0%
  • Ruby 21.0%