How to make ios app compatible with iphone4 devices (i.e 3.5 inch), which is already built in iphone 5 (4.0 inch screen) without creating different xib?
Use Autolayout to allow your app to correctly resize to the correct screen size.
Raywenderlich.com has a good tutorial to get you started, and the Cocoa Auto Layout Guide is excellent, although it is written primarily for Mac apps.
Related
I have an issue with the iPhone app. I have implemented one iPhone app (not universal). When I am creating the new project I have deleted the Launch Screen,Story board from the project and implemented the MainWindow.xib like in the old format. I have designed the xibs for iPhone 5. So in iPhone 5,6 and 6 plus everything is working fine. But When I run the iPhone app in the iPad the bottom part got cut off. If I design the xibs for iPhone 4, eventhough I added the Default-568h#2x.png it is not supporting for iPhone 5 but working well in iPad.For reference I have attached the screenshot . The screenshot for iPhone 5 screen. It is not scaling to iPhone 5 after adding the Default-568h#2x.png. Black color part width is 568-480=88 pixels.
So please guide me to handle the iPhone 4,5,6,6 plus and iPad.Thank you for spending the valuable time. Please let me know if I am not clear.
I am using xcode 8.0 and iOS 10.0
I have to develop an app that should run on all the iPhone devices, whether it is iPhone 4/4S, iPhone 5/5S, or iPhone 6/6+, using Xcode 6.1.1. Will an app developed using Storyboard run on devices prior to iPhone 5?
If not, then what things should I consider so that app will run seamlessly on all the iPhone devices?
Storyboard and ARC will work till iOS 5.
Apple Document:
Storyboard Compatibility
Note: This are Some Nice Tutorials About AutoLayout.
AppCoda,
raywenderlich
Try to adapt with Size classes and auto layout. First I didn't know how autolayout and sizeclasses work, and it was so tough for me. Yeah, now the problem with multiple screen is not a big deal anymore.
Please read apple's docs:
Auto Layout Link
Size Classes Link
When developing an app specifically for the iPhone 6 Plus, what resolution should the app be designed for? Should it be 1242×2208 or 1080x1920? Will an app designed for 1080x1920 fill the entire iPhone 6 Plus screen? Are there guidelines from Apple on this issue? I haven't found any. Thanks.
Apple's guideline for all devices is to stop hard coding screen sizes and use Autolayout. If yo are targeting the iPhone 6/6+ you can assume iOS8 and Xcode 6 which makes Autolayout much easier.
It you really want to work to a specific screen resolution, you should use 1242×2208 which is downscaled to 1080x1920 in hardware.
As the apple has announced the two more screen sizes iPhone 6 and 6 plus. What will happen to apps already in app store build for iPhone 4 and 5. Will they be stretched or their layout be distorted in these new phones?
Please help me because I have recently submitted two of my apps in app store waiting for review. So should I change them or they will work fine. As I haven't use Auto layout in these apps.
Thanks.
If you have uploaded apps from XCode 5.x apple will take care and they will be scaled and stretched to fit them in iPhone and iPhone 6. If you want to take advantage of new devices you will have to use XCode 6 and add launch images on your project with these steps.
If you have not added launch images for iPhone 6 and 6 plus (and do not have Launch Screen File for iOS 8) , than your apps will be streached to fit in new devices , once you add them app will not be streached and you will have to manage it.
So with Xcode 5.x , you can be absoulatly sure that iOS will take care and streach your app to look just like thy look in iPhone 5 or 5S.
As Bhumit said, you need to add launch images at the new sizes if you want to have your apps scale properly for iPhone 6.
A corollary is that they will not scale in the simulator until you add those launch images. You can just add some default ones to test - I recommend grabbing David Smith's blanks.
If you do not test in the simulator with launch images, you will get a false impression of your app working because the default scaling kicks in. (If you are happy to leave it with that default scaling, fine for now.)
According to the latest version of Xcode 6 , the apps running in the previous iPhone environments of 5 and 4s will work as they are in iOS 8 i.e iPhone 6 , 6+. I suggest you download Xcode 6 from the Apple Developer Site and run your apps in the iPhone 6 and 6+ and see for yourself.
I have also found the apple link for this problem. Under heading 'Supporting New Screen Sizes and Scales'. You can check out above link for more such information.
What is the approach to support different resolutions on MonoTouch. I just created a new XIB in the latest version of MonoTouch. When I run it, it is iPhone 4 resolution.
My simulator is iPhone5 and so I see black bars in top and bottom.
First off all you must provide default (launch) image for iPhone 5.
Possible solutions
Use the auto-resizing capabilities of iOS (View.AutoresizingMask)
Detect iPhone 5 and load different xib like in universal apps. Read more about this great in tutorial Building MonoTouch Applications that run on both the iPad and iPhone Getting Started from Xamarin Developer Center!