How avoided storyboard and overloading XIB with just right split between what is visually defined and what is programatically programmed:
- visual set-up of the view in Interface builder – only view, no controllers and setting up outlets but no actions. AddNoteView.xib . Justify controls, set up autoscaling etc..
- create AddNoteView.h with outlets
- create AddNoteView.m and hook awakeFromNib and setup additional settings on view- (void)awakeFromNib{
[super awakeFromNib];
CALayer * layer = [self.locationThumb layer];
[layer setMasksToBounds:YES];
[layer setCornerRadius:10.0];
- create AddNoteViewController.m and define loadView- (void)loadView {
self.view = [[UINib nibWithNibName:@”AddNoteView” bundle:nil] instantiateWithOwner:nil options:nil][0];
}