需要使用 IB_DESIGNABLE 和IBInspectable关键字
IB_DESIGNABLE
@interface MyButton : UIButton
@property (nonatomic)IBInspectable BOOL isOkButton;
@end
效果图如下:
isok.png
需要使用 IB_DESIGNABLE 和IBInspectable关键字
IB_DESIGNABLE
@interface MyButton : UIButton
@property (nonatomic)IBInspectable BOOL isOkButton;
@end
效果图如下: