Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

DDustiNN

macrumors 68020
Original poster
Jan 27, 2011
2,485
1,371
Hello, I'm hoping someone could help me. My app is a simple list view (like the stock Contacts app), so I assumed it would automatically just stretch to the larger screen size (thus showing a couple more lines of the list), since I used a built-in view type from the API.

I just got my iPhone 5, downloaded my app, and it is letterboxed onto a 3.5" screen. So I was obviously wrong.

I guess I'll have to put in an update, but... what do I update? What do I have to do to tell my app to display properly on the taller screen? Do I have to check for screen size and change something accordingly? Or is it just something simple I overlooked? I mean, is it a setting somewhere, or do I have to actually modify the code?

Thanks guys :D
 
Last edited:

DDustiNN

macrumors 68020
Original poster
Jan 27, 2011
2,485
1,371
First, you will need to add a Default-568h@2x.png image to your Launch Images. Then, you should run your app in the Simulator and see if your view(s) resizing are properly set up to handle the larger screen.

I haven't looked at Xcode in quite a while so I'm not 100% familiar with what that image is. Is that the splash screen that's displayed on app startup? I do have one of those. Are you saying I should have two different sizes of that screen, and then the app will automatically adjust everything else accordingly because it will choose the appropriate screen size on startup?

Just want to make sure I'm understanding correctly. Thanks for the response!
 

dejo

Moderator emeritus
Sep 2, 2004
15,982
452
The Centennial State
Are you saying I should have two different sizes of that screen, and then the app will automatically adjust everything else accordingly because it will choose the appropriate screen size on startup?

Actually, you should have three different sizes: 320x480 (for non-retina iPhone), 640x960 (for retina iPhone) and 640x1136 (for retina 4-inch iPhone). And if your app is universal, you'll have even more startup images for the iPad.

If the 640x1136 image is set properly, your app will run without letter boxing. As for whether it will "automatically adjust everything else accordingly", that all depends how you have the autoresizing, etc. setup for all your views.

You should get the latest Xcode and do some testing. It's kinda what developer previews are intended for.
 

R4z3r

macrumors member
Jan 19, 2009
98
42
NJ
I haven't looked at Xcode in quite a while so I'm not 100% familiar with what that image is. Is that the splash screen that's displayed on app startup? I do have one of those. Are you saying I should have two different sizes of that screen, and then the app will automatically adjust everything else accordingly because it will choose the appropriate screen size on startup?

Just want to make sure I'm understanding correctly. Thanks for the response!

Phone-only applications may only have one launch image. It should be in PNG format and measure 320 x 480 pixels. Name your launch image file Default.png.

For iPhone 4 high resolution, you can include an additional launch image. It should be in PNG format and measure 640 x 1136 pixels. Name it Default@2x.png. This image will get picked up by the iOS if your app is running on an iPhone 4.

For iPhone 5 high resolution, you can include an additional launch image.it should be in PNG format and measure xxx x xxx pixels. Name it Default-568h@2x.png. This image will get picked up by the iOS if your app is running on an iPhone 5
 

DDustiNN

macrumors 68020
Original poster
Jan 27, 2011
2,485
1,371
Actually, you should have three different sizes: 320x480 (for non-retina iPhone), 640x960 (for retina iPhone) and 640x1136 (for retina 4-inch iPhone). And if your app is universal, you'll have even more startup images for the iPad.

If the 640x1136 image is set properly, your app will run without letter boxing. As for whether it will "automatically adjust everything else accordingly", that all depends how you have the autoresizing, etc. setup for all your views.

You should get the latest Xcode and do some testing. It's kinda what developer previews are intended for.

Phone-only applications may only have one launch image. It should be in PNG format and measure 320 x 480 pixels. Name your launch image file Default.png.

For iPhone 4 high resolution, you can include an additional launch image. It should be in PNG format and measure 640 x 1136 pixels. Name it Default@2x.png. This image will get picked up by the iOS if your app is running on an iPhone 4.

For iPhone 5 high resolution, you can include an additional launch image.it should be in PNG format and measure xxx x xxx pixels. Name it Default-568h@2x.png. This image will get picked up by the iOS if your app is running on an iPhone 5

Thanks guys, this was helpful. I'll do that over the weekend and look into the auto-resizing thing.

Thanks again :cool:
 

DDustiNN

macrumors 68020
Original poster
Jan 27, 2011
2,485
1,371
Well that was simple. I downloaded the new Xcode, and it seems that adding the Default-568h@2x.png launch image has done the trick... tested out perfectly in the simulator. Now it's just waiting for review in the App Store.

On another note, it looks like I was forced to drop support for armv6, and I had to bump up my minimum supported version to iOS 4.3... bummer, for such a simple app.

Thanks for the help guys :D
 

xStep

macrumors 68020
Jan 28, 2003
2,031
143
Less lost in L.A.
For iPhone 4 high resolution, you can include an additional launch image. It should be in PNG format and measure 640 x 1136 pixels. Name it Default@2x.png. This image will get picked up by the iOS if your app is running on an iPhone 4.

That 1136 is wrong for iPhone 4. That is the height for iPhone 5. dejo listed them.

----------

Well that was simple. I downloaded the new Xcode, and it seems that adding the Default-568h@2x.png launch image has done the trick... tested out perfectly in the simulator. Now it's just waiting for review in the App Store.

On another note, it looks like I was forced to drop support for armv6, and I had to bump up my minimum supported version to iOS 4.3... bummer, for such a simple app.

Thanks for the help guys :D

Did you test on several devices or several simulator resolutions at least? Simply adding the image tells iPhone 5 what resolution to use. It can't account for other issues like resizing views, and the rotation issue that has been mentioned here a couple of times.

If you have kept an older version of Xcode handy, potentially you could use that to compile an armv6 binary and use a command line tool, lipo I think, to combine with the other the newer binary. I'm not sure how that would all work or if it is really possible with the store destined package. Might be a very big hassle.

BTW, what is the app?
 

R4z3r

macrumors member
Jan 19, 2009
98
42
NJ
That 1136 is wrong for iPhone 4. That is the height for iPhone 5. dejo listed them.

Sorry, copied from over an area of developer.apple.com. Your right though, should have said:

Device:
iPhone and iPod touch
320 x 480 pixels
640 x 960 pixels (@2x)

iPhone 5 and iPod touch (5th generation)
640 x 1136 pixels (@2x)

iPad
768 x 1004 pixels
1536 x 2008 pixels (@2x)

iPad Landscape
1024 x 748 pixels
2048 x 1496 pixels (@2x)
 

DDustiNN

macrumors 68020
Original poster
Jan 27, 2011
2,485
1,371
Did you test on several devices or several simulator resolutions at least? Simply adding the image tells iPhone 5 what resolution to use. It can't account for other issues like resizing views, and the rotation issue that has been mentioned here a couple of times.

If you have kept an older version of Xcode handy, potentially you could use that to compile an armv6 binary and use a command line tool, lipo I think, to combine with the other the newer binary. I'm not sure how that would all work or if it is really possible with the store destined package. Might be a very big hassle.

BTW, what is the app?

Yeah I tested on all 3 iPhone resolutions.

I found an armv6 workaround online, tried it out but it was quite a hassle and still giving me errors, so I just switched it back to armv7 and iOS 4.3, then it worked perfectly. I noted that change in the update too, so that anyone using an old device (iPhone 3G, iPod Touch G1 or G2) or iOS 4.2.6 or lower should not update.

My app is called Mortal Kombat Pocket Guide. I just made it as a school project last year and to learn the basics of iOS development. Figured I'd put it on the store to make my $100 back, but it still sells a surprising amount considering there are better ones. In fact I bought a different one and use that personally, lol. I even emailed the guy and told him, and we went back and forth for a bit as he told me some cool stuff about how he made his.

Anyway, that app has already paid for my developer license last year and this year, plus quite a bit of profit, so now I want to make some more. I have ideas for some apps I want to do, just gotta find the time!

Sorry, copied from over an area of developer.apple.com. Your right though, should have said:

Device:
iPhone and iPod touch
320 x 480 pixels
640 x 960 pixels (@2x)

iPhone 5 and iPod touch (5th generation)
640 x 1136 pixels (@2x)

iPad
768 x 1004 pixels
1536 x 2008 pixels (@2x)

iPad Landscape
1024 x 748 pixels
2048 x 1496 pixels (@2x)

Yep I got it, knew what you meant, haha. Actually Xcode tells you what the resolution should be when choosing your images too, so no confusion here :cool:
 
Last edited:
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.