Latest 1.0.0
Homepage https://github.com/mobilemagicdevelopers/UIColor-iOS7Colors
License MIT
Platforms ios , requires ARC
Authors

UIColor+iOS7Colors adds convenience accessors for some nice looking colors for iOS 7 I found
on ios7colors.com.

Usage

Use this the same way you use any other category. You should be able to use the familiar UIColor static
helper syntax.

  1. #import "UIColor+iOS7Colors.h"
  2. [UIColor iOS7orangeColor]
  3. Profit

Gradients

Gradient usage is a smidgen more complicated because gradients are more complicated. Here’s a snippet (slighly modified
for clarity) from a recent project that was the impetus for my adding gradients:

NSArray *gradientColors = [UIColor iOS7greenGradient];
CGColorSpaceRef colorSpace = CGColorSpaceCreateDeviceRGB();

CGGradientRef gradient = CGGradientCreateWithColors(colorSpace, (CFArrayRef)gradientColors, NULL);
CGColorSpaceRelease(colorSpace), colorSpace = NULL;

CGPoint startPoint = square.origin;
CGPoint endPoint = CGPointMake(square.origin.x, CGRectGetMaxY(square));
CGContextDrawLinearGradient(context, gradient, startPoint, endPoint, 0);
CGGradientRelease(gradient), gradient = NULL;

Kudos

License

MIT License

Latest podspec

{
    "name": "UIColor+iOS7Colors",
    "version": "1.0.0",
    "summary": "Convenience accessors for some nice looking colors for iOS 7.",
    "description": "                   UIColor+iOS7Colors adds convenience accessors for some nice looking colors for iOS 7 I found on ios7colors.com.n                   n                   Kudos:n                   I'm using colors listed on ios7colors.comn                   I got the idea to make an extension from Class Lange's iOS7Colorsn                   I got the idea to add gradients from Jason Grandelli's KXKiOS7ColorsAndGradientsn                   I got the idea for the macros from Tomer Shiri's Objective-C-Genericsn",
    "homepage": "https://github.com/mobilemagicdevelopers/UIColor-iOS7Colors",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "D. Patrick Caldwell": "[email protected]"
    },
    "social_media_url": "http://twitter.com/tncbbthositg",
    "source": {
        "git": "https://github.com/mobilemagicdevelopers/UIColor-iOS7Colors.git",
        "tag": "v1.0.0"
    },
    "source_files": "lib/UIColor+iOS7Colors.{h,m}",
    "requires_arc": true,
    "platforms": {
        "ios": null
    }
}

Pin It on Pinterest

Share This