Swift – Xcode6: IBDesignable and IBInspectable with Objective-C

objective cswiftxcode6

I have an Objective-C UI component that I'd like to make inspectable in Interface Builder with Xcode 6. Swift has the @IBDesignable and @IBInspectable declaration attributes. Are they available also in Objective-C? How are they used?

Best Answer

Code example:

#import <UIKit/UIKit.h>
IB_DESIGNABLE
@interface LOLView : UIView
@property (nonatomic) IBInspectable UIColor *someColor; 
@end