I have created a with left bar button item added from storyboard, titleView and three right bar button items from code.
Here is the code:
override func
You can also wire things up first in Storyboard.
I have two right bar button items.
(This is objective-c code, which you can modify for swift.)
First create references to them in view controller.
@interface MyViewController ()
@property (weak, nonatomic) IBOutlet UIButton *smsButton;
@property (weak, nonatomic) IBOutlet UIButton *checkoutButton;
@end
Then, in viewDidLoad, adjust their widths and heights.
// Adjust right bar button item spacing.
self.smsButton.frame = CGRectMake(0, 0, 30, 30);
self.lockButton.frame = CGRectMake(0, 0, 30, 30);