iOS App is offset from the top of the Screen - ios

I am developing an app (objective c) with a navigation controller. For some reason the whole app is offset from the top of the device. See below, can anyone give me some pointers as I have no idea.
Hiding the Navigation bar makes no difference, either in the storyboard or in code. The storyboard constraints all seem correct, as the title below the navigation bar moves up and down when showing and hiding the navigation bar.
This problem occurs on iPhone SE and iPhone 7, the iPad 2 is ok. The xCode version is 8.1
Any help would be appreciated.

You need to use launch.storyboard in your Project or you need to add launch screens image in your Asset Folder for all the sizes, then this black screen from top and bottom will be removed.

In App Icons and Launch Images setting, you need to set asset and launch screen file. so this black bar will disappear.

Related

UIPopoverController with navigation bar inconsistent on device and simulator

I have a simple popover for a UINavigationController that is anchored on the root views right bar button item. On the iPhone simulator (I tried it on various devices) the navigation bar of the popover aligns nicely with the navigation bar of the root view. I assume this is taken care of by UIKit. Here is a screenshot of the simulator.
However on my physical device there is a slight offset. This is a screenshot on my iPhone 6 physical device. It's weird because there's no offset for the iPhone 6 simulation. Notice they bottoms of the navigation bars are not aligned.
I couldn't find any stack overflow questions addressing this and I'm not sure how to fix it since all we're "supposed" to do is specify the popover anchor (as the plus button) and let UIKit take care of the rest. Is there any way to fix this programmatically? I'm not using storyboards or xibs. I also have touch assist enabled on my physical device.

screen breaking in iPhone x for higher iOS versions.there is no storyboards design done through code

In my project tabbar(it's like below the navigation bar i have 4 buttons in my tabbar) is going to top after app launches it's happening in iPhone x for higher iOS versions.we are not using storyboards,design done through codeing.check below screenshots.
In the first screenshot u can't see search bar and above tabs[location,search,deals this is the problem.
if u observe second one u can see address bar and above tabs for lowerversions it was working.
This is breaking screen for higher versions above ios11
This is for lower versions design is fine

Top navigation is not coming properly - iPhone Apps must also run on iPad without modification, at iPhone resolution, and at 2X iPhone 3GS resolution

My App is iPhone only and it works great on iPhone device. It got rejected by Apple with below message:
iPhone Apps must also run on iPad without modification, at iPhone
resolution, and at 2X iPhone 3GS resolution
When I run my app on iPad it's cutting part of the navigator at the top. Attached is the screen print.
Anyone got any clue how to fix it?
I think you navigation bar is covered because its position is lower than the 20point reserved for the status bar. To check its position, click on the navigation item or bar, go to Size Inspector and under View, you will see the X & Y positions. Or you can set constraints for it. I hope this helps.
Actually I solved this problem long back but missed to update the solution here. I was getting this issue on iPad because it doesn't use status bar as like iPhone for iPhone app. So I did leave the status bar space at the top of the view controller. Also, this issue occurs only for standalone ViewController and if we use Navigation ViewController, issue is automatically resolved.

blank view on top of Nav Bar in ios Simulator?

How do i get rid of this top and bottem blank view ?
Evrything is set to none.
This is a known issue. You can add a launch screen file that appears to work for multiple screen sizes. see How to enable native resolution for apps on iPhone 6 and 6 Plus?
Add proper launch screen files to resolve your issue

UITableView size in both i0S7 and iOS5

I am having trouble getting my table view to size correctly on 3.5 inch iPhone between the two iOSs.
I have a tabbar (native). I cannot use auto layout because its not compatible with iOS versions < 6.0. So Xcode tells me.
If I size for iOS 7 it gets cut off by the tab bar so i move it up but then it is in the middle of the screen for iOS 5. and visa-versa. Not to mention when I go and try it on a 4 inch screen.
The Autosizing Attribute in Xcode IB seems to be no help either. (Not the checkbox the lines)
In the pic below this is set for iOS 7 running it on iOS 5. If I move it to the bottom of the black, which is not the bottom of the screen, it will be underneath the tab bar when ran.
I have played a round for some time with different configurations but I cannot seem to hit it right. What am I missing?
You have 2 choices.
Either set the tab bar translucency to NO
if ([self.tabBarController.tabBar respondsToSelector:#selector(setTranslucent:)])
[self.tabBarController.tabBarController.tabBar setTranslucent:NO];
or put this in your viewDidLoad in your controller
if ([self respondsToSelector:#selector(setEdgesForExtendedLayout:)])
[self setEdgesForExtendedLayout:UIRectEdgeNone];

Resources