1

I have a presented view controller in iOS 7 that doesn't have a navigation bar, but the status bar is visible. I tried setting the edgesForExtendedLayout to UIRectEdgeNone, but that doesn't seem to do anything (unless I show a navigation bar, which I don't need).

Doesn't seem to be a topLayoutGuide in interface builder (view uses a nib, not a storyboard) and was having trouble with that anyway.

Could hide status bar like this:

[[UIApplication sharedApplication] setStatusBarHidden:YES];

But I don't really want to hide it. Note there are some similar questions, but they discuss using a navigation bar. This one, I don't want the navigation bar.

Screenshot: https://i.stack.imgur.com/6OW9F.png

EDIT: Switched to using a storyboard and was able to get the top layout guide working properly

shim
  • 9,289
  • 12
  • 69
  • 108
  • If you uses a UISearchDisplayController you can do this to add the searchbar to the navigationbarcontroller. Code: `UISearchDisplayController.displaysSearchBarInNavigationBar = YES;` – Gustaf Rosenblad Sep 20 '13 at 20:59
  • Not presenting with a navigation controller – shim Sep 20 '13 at 21:35

1 Answers1

0

Switched to using a storyboard and was able to get the top layout guide working properly

shim
  • 9,289
  • 12
  • 69
  • 108