Vibhooti Vibhooti - 1 year ago 177
iOS Question

Add top layout guide in NIB file (XIB)

How can I add top layout guide in NIB file or how can I specify space from the top navigation bar and status bar so that it does not create problem between ios 6 and iOS 7?

Answer Source

You can do this by by implementing new property called edgesForExtendedLayout in iOS7 SDK

-(void)viewDidLoad {
      if ([self respondsToSelector:@selector(edgesForExtendedLayout)])
         self.edgesForExtendedLayout = UIRectEdgeNone;


If you are using navigation bar and xcode5 then..

In Interface Builder,select view controller, and then navigate to the attributes inspector. In "Extend Edges". check Under Top Bars

i have solved my problem from Here

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download