Latest 0.3.0
Homepage https://github.com/Polidea/PLXColors
License MIT
Platforms ios 6.0, osx 10.8, requires ARC
Authors

CI Status
Version
License
Platform

PLXColors is a small library that allows you to create UIColor or NSColor objects based on the hexadecimal representation of the
colors, similar to that used in HTML and CSS languages. UIKit/AppKit allows you to create UIColor/NSColor objects only with floating
point numbers which is inconvenient when you get these values from graphics programs.

Usage

To run the example project, clone the repo, and run pod install from the Example directory first.

Methods

PLXColors provides four methods to create UIColor or NSColor objects:

+ (PLColor *)colorWithHexString:(NSString *)hexString;
+ (PLColor *)colorWithHexStringWithAlpha:(NSString *)hexString;
+ (PLColor *)colorWithHexInteger:(NSUInteger)value;
+ (PLColor *)colorWithHexIntegerWithAlpha:(NSUInteger)value;

where PLColor is UIColor or NSColor class depends on target platform.

See the code or Documentation to check in which format should be parameters.

Requirements

  • iOS6 or OS X 10.8

Installation

PLXColors is available through CocoaPods. To install
it, simply add the following line to your Podfile:

pod "PLXColors"

Author

Michał Laskowski, [email protected]

License

PLXColors is available under the MIT license. See the LICENSE file for more info.

Latest podspec

{
    "name": "PLXColors",
    "version": "0.3.0",
    "summary": "Creating UIColor / NSColor objects based on the hexadecimal representation of the colors.",
    "description": "PLXColors is an UIColor and NSColor category that provides methods that allows you to create UIColor or NSColor objectsnbased on the hexadecimal representation of the colors, similar to that used in HTML or CSS language.",
    "homepage": "https://github.com/Polidea/PLXColors",
    "license": "MIT",
    "authors": {
        "Michau0142 Laskowski": "[email protected]"
    },
    "source": {
        "git": "https://github.com/Polidea/PLXColors.git",
        "tag": "0.3.0"
    },
    "platforms": {
        "ios": "6.0",
        "osx": "10.8"
    },
    "requires_arc": true,
    "source_files": "Pod/Classes",
    "ios": {
        "exclude_files": "Pod/Classes/NSColor+PLXColors.h",
        "frameworks": "UIKit"
    },
    "osx": {
        "exclude_files": "Pod/Classes/UIColor+PLXColors.h",
        "frameworks": "AppKit"
    }
}

Pin It on Pinterest

Share This