Helper for displaying country flags, rendered from SVG files with help of SVGImage pod.
To run the example project, clone the repo, and run pod install
from the Example directory first.
This pod is using SVGImage https://bitbucket.org/sodastsai/svgimage and derives all it's requirements
CFCountryFlags is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod "CFCountryFlags"
You can also try to point your cocoapods directly to this repository pod 'CFCountryFlags', :git => 'https://github.com/codingfingers/CFCountryFlags.git'
Add following import to your class: #import <SVGImage/SIImage.h> #import <CFCountryFlags/CFCountryFlags.h>
Create SIImage class with flag: SIImage *svgImage = [CFCountryFlags flagImageForCode:@"PL"];
Use UIImage property to get rendered class:
[self.flagView setImage:[svgImage UIImage]];
Marcin Lepicki, marcin@codingfingers.com http://codingfingers.com - Mobile Software House. We develop iOS and Android native apps.
CFCountryFlags is available under the MIT license. See the LICENSE file for more info.