Launch Image working on iPhone 4 & 5 but not on iPhone 6 and 6 plus in Objective-C - ios

I've set launch images by going in Asset Catalog for iPhone 4,5, 6 and 6 plus. I know the dimensions for images and I've used them correctly. I've named the launch image for iPhone 6 and 6+, Default-667h#2x.png and Default-736h#3x.png respectively. But still the launch images that I've set for iPhone 6 and 6 plus are not working where as the images for iPhone 4 & 5 are showing up. Please help. Thanks in advance.

Apple removed LaunchImage from iOS 8. Now if you want to show splash screen you need to use LaunchScreen.xib which now is creating with new project or another xib or storyboard that can be selected in "App Icons and Launch Images" section in "General" tab of your project settings.
From developer docs: "On iOS 8, the launch screen file will be used, and on iOS 7, the launch images will be used."
Docs for launch screen here.

I got it working by emptying the text box in front of Launch Screen File.
Though it will work if I add the image on LaunchScreen.xib, but for those of you who don't want that xib they need to left the Launch Screen File nil.

Related

iOS View Controller size is 4 inch on iPhone 6

I have iPhone oriented application, the UI created using a storyboard, when I run it on 4.7 or 5.5 inch devices it presented as 4 inch screen with black empty space on top and bottom of window.
The project was created on Xcode 6 and I got the issue when I compile it with Xcode 7 but I'm not sure if it's related.
On Xcode 7 you must add the launch screens (on "images.xcassets") of your desired resolution (iphone6 , iphone5...) or instead you can add the splash screen that automatically will work for all resolutions (YourProjectName/General/App Icons and Launch Images).
Hope this helps.
You haven't add added Launch Images with proper resolution in proper place. So your app is considering it only for iphone5 not above so.Place launch Images properly.It will help.Thanks
Here are Apple's answers:
If you don't use launch images, but you do have a Launch Screen (nib
or storyboard) then we synthesize your launch screen at install time.
If you don't have any launch images, and you don't have a launch nib
or storyboard, then you are declaring that you don't support any
screen sizes aside from 320x480
A brand new project should not demonstrate any of these issues
With the iPad Pro you will need a Launch Screen to support the new
screen size (and you need Launch Screens to support multitasking on
iPad in general).

Do I have to have LaunchScreen.xib for iOS 8 launch images?

I'm using Xcode 6.1.
In Launch Image sources = LaunchImage and in Launch Screen File = Main_iPhone. In Images.xcassets under Launch Image Name = LaunchImage.
I currently have a Retina HD 5.5 and Retina HD4.7 Launch Image in appropriate sizes for iOS 8. Yet for all iOS 8 devices whether on iPhone 4s, iPhone5's, or iPhone 6's, iOS 8 doesn't load Launch Image. I don't use xib, only storyboards. However, do I have to create an xib file called LaunchScreen.xib and put my iOS 8 Launch Images in that file for iOS 8 to launch the images?
So i'd put just 2 iOS 8 images in there and xib has no problem with me using storyboards to build game? Is that the only way for a Launch Image to work for iOS 8 in Xcode 6.1?
edit:
So I just made a LaunchScreen.xib file. In that file I put my Retina HD 4.7 inch launch image for the 4.7 inch screen. In Launch Screen File I put as LaunchScreen.xib I still get the same result. iOS 7 launch images load but iOS 8 launch images don't load.
I had the same problem but had marked the xib as a launch screen, but just needed to select it as the launch xib in the build settings, general tab.
Have you marked the view in the xib as "Use as Launch Screen" in the File Inspector?

not using fullscreen iOS App Xcode 6.0 iphone5s

I have a simple out of box app that doesn't use the entire screen when I deploy it on a iphone5s. By default it creates a LaunchScreen.xib. I have not edited this file on purpose.
Black Bars top and bottom
Other answers suggest to add a Default-568h#2x.png launch image, but I am not using a launch image, and I am not sure where to add these. I see a place for this in the Images.xcassets by clicking the + icon and selecting New Launch Image.
Do I need to add a New Launch Image to Images.xcassets? If so what is the point of having a LaunchScreen.xib?
Thanks!
To get the app to display full screen:
As suggested here (https://stackoverflow.com/a/15328339/4347877), you must include a Default-568h#2x.png launch image (for iOS 7 or earlier). Or if your deployment target is iOS 8 or higher, you have the option of using LaunchScreen.xib.
Why Use LaunchScreen.xib?
For iOS 7 and earlier, app developers had to provide separate launch images for all screen sizes, resolutions and orientations their app supported. For universal apps, up to seven images were required: retina and non-retina versions for 3.5-inch iPhones in portrait and for iPads in portrait and landscape; and another retina image for 4-inch iPhones (the iPhone requires no landscape version because apps are always launched from the portrait-only Home screen).
Creating these images is a nuisance. Xcode 6 comes to the rescue by allowing you to specify a storyboard whose initial view controller will then be used as the app’s launch screen.
If you want to add a launch image instead of using LaunchScreen.xib:
Click on your Images.xcassets folder, right-click in the left pane, and select "New Launch Image." Once you have the correct launch image sizes for all devices you would like to support, drag each image to its respective slot (e.g. "Retina HD 5.5" or "iPhone Portrait 2x"). Before Xcode 6 introduced LaunchScreen.xib I used to create my launch image size here: http://www.appiconsizes.com.
Okay the solution I found came from this question. The answer from James Nick Sears actually fixes my problem. This is after adding the Launch Images. It should be noted that launch images using the images.xcasset is the prefered way to do this pre iOS 8.0 and the only way to make your app compatible with devices running iOS 7 and earlier.
I suggest using TiCons to create the icons, the mapping took me longer then it should have to figure out. In xcode you can see the expected image size for each device by selecting the empty image box and looking in the attribute inspector window on right.
But the real kicker is clicking the 'use asset catalog' button on the "App Icons and Launch Images" of your apps settings under the General tab. Once you click Migrate you can select your LaunchImages from the selection menu that resides where the button used to be, after "Launch Images Source". Without doing this your app won't work correctly on pre iOS 8 devices.

iOS 7 app doesn't fill the whole screen in Xcode 6 simulator

iOS 7 app doesn't fill the whole screen in Xcode 6 simulator. But when i set the app to target iOS 8, it works fine. Here are two screen captures:
This is for iOS 7
This is for iOS 8
Can someone help me?
You can try these solutions:
Try to create launch images(640*960 #2x.png & 640*1136 -568h#2x.png) and set them into project properties for "Launche images source".
or
Create .xib file with active autolayout and set this file as "launch screen file".

Launch image for iOS 7 iPhone

all!
I have a problem. I've created launch images for my app. I added them through assets catalog.
Ipad ios 6 and 7 works, but iphone works only for ios 6. Ios 7 on iphone shows only black screen (for all: 3, 3 retina and 4 inch), and then app starts, but launch image don't shows.
Yes, iOS6 and iOS7 require you to insert separate launch images for each… Actually, technically, the 2x iOS7 and 2x iOS6 iPhone launch images can be identical, and the R4 iOS7 and R4 iOS7 launch images can likewise be identical, but they are associated separately in the images.xcassets folder based on version.
To guarantee you have launch images associated with each version, go to Targets > General then go to "Launch Images":
Then select all of your supported devices in the right-hand menu under the 3rd tab (in this screenshot from my particular app, only portrait interface is available for iPhone, but if your app also supports landscape, landscape should show up here too). To find out the "expected size" of each launch image, select its placeholder then scroll down to look for the "expected size" also in the right-hand menu. And finally drag the appropriate images into the appropriate placeholder slots to make sure your app has launch images suitable for each device/interface.
I have faced same problem few days ago and i posted my Answer in this question-
iPhone application developed in X-code 5, not showing icon and launch image while running on iPad
Hope it help you.

Resources