White bar on bottom of app Xcode - ios

How can I remove the white bar at the bottom of my mobile app? I've tried the solution of adding a Launch screen in the Launch screen file but that didn't work. I've attached an image.
Just for a bit of context, I'm using a PageViewController to slide between 3 pages.
Any help appreciated.

It looks like you add static size view on the iPhone 6 screen in xcode UI constructor but launch it on the iPhone 6s Plus (with bigger screen).
To scale this view properly you should turn on Use Auto Layout in the Utilities bar and add constraints to the view

Make sure that the blue-colored view is properly constrained to the bottom of its superview.

Related

iPhone X compatibility programmatically

I want to make my app compatible with iPhone X. I'm not using storyboard or xibs, just code. When I run my app on the simulator the view overlaps part of the status bar and the home bar at the bottom. Is there a way to programmatically adjust the view so that it fits within the bounds? Any help is appreciated.
I believe the answer you are looking for is called safeAreaInsets, which are basically insets that considers the position of the iphoneX exclusive UI components such as the navigation bar and the home bar.
You should adjust the sizes and constraints of your UI components according to the safe area as opposed to the screen, for and non iphoneX devices, it would be 0, which means it would be the same as adjusting according the the screen sizes instead.
The docs for it is at:
https://developer.apple.com/documentation/uikit/uiview/positioning_content_relative_to_the_safe_area

iPhone X tool bar issue at the bottom

My app works well on all device except for iPhone X.
On iPhone X the tool bar on the bottom is shown like as shown in image
But I want to show it like shown in second image
But when ever I shift the tool bar up so that it will show properly on iPhone X then it also move upwards in other devices.
How should I solve this problem.
Actually the bottom bar of my view is inside another view thats why it is not extending accordingly.
So simply putting the bottom bar outside, on the main view and adjusting the constraint simply resolve my issue.
In my case My toolbar's bottom constraint was attached to superview's bottom. Changing it to Safe Area bottom resolved the issue for me

Double Navigation Bar in View

I have a problem with a "double" navigation bar in a screen of my iPhone app.
Starting position:
Xcode 8, Swift
I have a TableView with static lines that is embedded in a navigation controller. From the first cell I then call a screen (Segue Show Detail), which is very complex (labels, text boxes, buttons, etc.). When I execute the "Reset to suggested constraints" function on the screen, the screen is supplied with "generated" constraints. This is still clear. When I run my app in the simulator (iPhone 6) or my own iPhone 6, I see on the above screen a status bar, then my right navigation bar (Back button, title) and below an "empty" 2.Navigation bar. This decreases the screen down and is no longer fully visible. If I delete the constraints for the screen with the "Clear Constraints" function, the screen in the simulator (i6) looks good as I develop in the storyboard for the iPhone 7. But when I connect my own iPhone 6 and test, the screen does not fit completely to my iPhone, because right and down is something truncated.
I suspect the error in the "generated" constraints.
Now my question:
How can I check the generated Contraints (well over 100) for errors?
In the Internet and the forum I found nothing, which could help me.
Workaround for me:
The top UI element on the screen is a label across the entire width of the screen. For this label, I set a constraint manually, in addition to the generated constraints
Label.top = Top Layout Guide.bottom + 44,
whose value I then change to the value
Label.top = Top Layout Guide.bottom
This causes the label to slide directly below the status bar in the storyboard. The navigation bar is then no longer visible in the storyboard. This makes the placement of UI-Elements at the bottom of the screen somewhat more difficult because you do not know exactly which space is still available.
The display in the simulator (i6) and on my iPhone 6 looks however through the workaround ok.
For your help I would be very grateful.
Greeting Reinhard

Legacy iOS app not stretching properly

I have a layout issue. I'm trying to make a legacy 3.5in app work on iPhone 5. As soon as I give it the Default-568h#2x.png splash image, the whole app gets aligned to the top of the screen, leaving a huge white gap at the bottom. The autosizing struts and such seem to be set properly (not using Autolayout at the moment), but the thing doesn't stretch to fill the screen. I'm not sure where to look next. I just want my poor tab bar to be at the bottom!
Since you're not using AutoLayout, now is a great time to start. Xcode 5 makes setting constraints a simple exercise.
I suspect that your tab bar frame is hard-coded to certain x, y, width, height coordinates which work well on the 3.5" screen. You can also see how your view renders on taller screens by pressing this button in the Xcode 5 Interface Builder:

ios - why do the screens on the storyboard look different (space inserted) that when I run the program?

I have this screenshot of my storyboard which looks ok, and then the simulator which has some weird whitespace block on the screen.
The simulator is retina 4-inch ios6 simulator. Is this not a correct simulator? Or is there something else I am doing incorrectly?
Thanks!
There could be two problems here.
Your constrains or springs and struts are set wrong.
Inside of Interface Builder your scroll view is scrolled down. If you have more content in a scroll view than what can be held in that scroll view, then you can scroll within that scroll view.
More than once, I've confused myself because a particularly large table view wasn't showing the table cell prototype I was looking for. My storyboard is big and I would end up hunting around for it until I realized that it's merely scrolled off the bottom.
Retina 4-inch corresponds to iPhone 5 but your storyboard's controllers view are setting for Iphone 3/4
Notice the 7 bottom right buttons inside your storyboard. Out of those 7 buttons, the one on the extrem left, will toggle your storyboard views for 3.5-inch to 4-inch displays. Since currently your storyboard is set for 3.5-inch display but you are running on a 4-inch simulator, thats the reason for the inconsistency

Resources