Skip to content

Instantly share code, notes, and snippets.

@Ashton-W
Created November 6, 2014 05:09
Show Gist options
  • Save Ashton-W/94097b30829ba3e24b2f to your computer and use it in GitHub Desktop.
Save Ashton-W/94097b30829ba3e24b2f to your computer and use it in GitHub Desktop.
IBInspectable default values in Objective-C for IB_DESIGNABLE Views
- (instancetype)initWithFrame:(CGRect)frame
{
self = [super initWithFrame:frame];
if (!self) {
return nil;
}
[self inspectableDefaults];
return self;
}
- (instancetype)initWithCoder:(NSCoder *)aDecoder
{
self = [super initWithCoder:aDecoder];
if (!self) {
return nil;
}
[self inspectableDefaults];
return self;
}
- (void)inspectableDefaults
{
_tintImage = YES;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment