The split view controller has a two column layout the master column on the left and the detail on the right. I want to be able to set the width of the columns.
I came across this solution in stack overflow. It works but does not respond to numbers over 410 which means I can't make the split 50/50. Any ideas why it is limiting me and how I get around it? Thanks
edit: This is an iPad only project not iPhone
From stack overflow
I came across this solution in stack overflow. It works but does not respond to numbers over 410 which means I can't make the split 50/50. Any ideas why it is limiting me and how I get around it? Thanks
edit: This is an iPad only project not iPhone
From stack overflow
Code:
In IOS 8.0 you can easily do this by doing the following:
In your MasterSplitViewController.h add
@property(nonatomic, assign) CGFloat maximumPrimaryColumnWidth NS_AVAILABLE_IOS(8_0);
In your MasterSplitViewController.m viewDidLoad method add
self.maximumPrimaryColumnWidth = 100; self.splitViewController.maximumPrimaryColumnWidth = self.maximumPrimaryColumnWidth;
This is a really good, simple and easy feature of IOS 8.
Last edited: