My login view has a subview which has a UIActivityView
and a UILabel
saying "Signing In…". This subview has corners which aren't rounded. How can I make them round?
Is there any way to do it inside my xib?
My login view has a subview which has a UIActivityView
and a UILabel
saying "Signing In…". This subview has corners which aren't rounded. How can I make them round?
Is there any way to do it inside my xib?
You can use following custom
UIView
class which can also change border color and width. As this isIBDesignalbe
You can change the attributes in interface builder as well.Try this
...
Note: If you are trying to apply rounded corners to a
UIViewController
's view, it should not be applied in the view controller's constructor, but rather in-viewDidLoad
, afterview
is actually instantiated.Please import
Quartzcore framework
then you have to setsetMaskToBounds
toTRUE
this the very important line.Then:
[[yourView layer] setCornerRadius:5.0f];
Do this programatically in obj c
We Can Also do this from stoaryboard.
ON Xcode 6 Your try
or
You can also use an image: