The best way to overcome this in iOS 7 is by conforming to the new UIBarPositioningDelegate
protocol.
You connect the delegate of your NavigationBar to your view controller (set your view controller as the delegate for the navigation bar either through storyboard or through code) and conform to that protocol and by implementing the method
-(UIBarPosition)positionForBar:(id<UIBarPositioning>)bar {
return UIBarPositionTopAttached;
}
You can remove the top gap in the view controller. You need to place the bar 20 points below the top edge