Latest 1.0.0
Homepage https://github.com/jprothwell/UIViewRoundedCorners
License MIT
Platforms ios 9.0

UIView+RoundedCorners category

This adds rounded corners to just the corners which you want rounded not all of them like the new CALayer cornerRadius.

Usage

Import the category first:

#import UIView+RoundedCorners.h

Use the following to round all corners:

[myView setRoundedCorners:UIRectCornerAllCorners radius:10.0];

For Top Left and Top Right:

[myView setRoundedCorners:UIRectCornerTopLeft|UIRectCornerTopRight radius:10.0];

Here I have used the inbuilt enum UIRectCorner for specifying the rounded corners. So its much simpler to implement.

Support

iOS 5 only for demo as I am using ARC, but the core UIView category should work with iOS 3.2+

License

Under a Creative Commons Attribution 3.0 Unported License

Latest podspec

{
    "name": "UIViewRoundedCorners",
    "version": "1.0.0",
    "summary": "UIViewRoundedCorners",
    "description": "awesome! UIViewRoundedCorners",
    "homepage": "https://github.com/jprothwell/UIViewRoundedCorners",
    "license": "MIT",
    "authors": "Leon",
    "source": {
        "git": "https://github.com/jprothwell/UIViewRoundedCorners.git",
        "tag": "1.0.0"
    },
    "source_files": "UIViewRoundedCorners/UIView+RoundedCorners.{h,m}",
    "platforms": {
        "ios": "9.0"
    }
}

Pin It on Pinterest

Share This