So far I've only dealed with iPhone Apps and the time has come to make them universal. I was watching the lecture about universal Apps by Paul Hegarty on iTunesU and some questions poped into my head.
If I understood the concep allright the main difference between an iPad and an iPhone (when coding) is that the iPad allows the splitview controller and one should take advantadge of it, right?
What Mr. Hegarty did was to adapt the code on one App and add conditionals to differ when the App was running on an iPad or an iPhone.
My question is, is that the usual way it is done? I am a very organized guy and I like stuff to be as much structured as possible. So my first though was to create a complete set of view controllers to manage the iPad storyboard rather that have a single view controller filled with code for both devices.
is it possible to do so as well? what is considered to be a good practice?
Thanks in advance!
I think a good practice for a universal app would be reuse as much code as possible. Otherwise, why not create two different apps?
There are not that many differences between iphone and ipad controls except on iPad we can use popover and split view. So I would share the code in view controller as much as I can.
I just published a git for "converting" iPhone app into Universal app. Take a look - https://github.com/BTLibrary/BTSplitViewController
Related
I've created full app for iPhone, but I need to make iPad version. mostly the app is lists, but login screen, logo and cells are too small (just to repeat - it was created for iPhone). Is there any way to create iPad user interface or stretch phone views?
Thatnks for your help. Btw sorry if it's duplicate of some similar question. Just couldn't find it (maybe bad keywords).
You absolutely should have separate XIBs for iPad & iPhone. Now, if you want to try and save some work and start from the iPhone XIBs as your base point, you should take a look at the top two answers from this question:
Xcode 4 .xib Create iPad Version
I have an iPhone application developed with iOS and I need to convert the application to universal so the app can appear in the iPad apps section of AppStore.
It just so simple as changing the Device section in my project to universal or I have to re develop the app, create new views, etc?
It depends strictly on your app, but generally speaking, yes, you will need to create new views.
I mean, even if you want to keep exactly the same UI, chances are that it will be more convenient to provide iPad specific versions of your xib files, or adapt the views you created programmatically. This is due to the fact that the iPad is not simply larger: it has got different ratio (3:4 vs. 2:3) and this changes things completely. You might try to play with autoresizing settings for your views and grouping views to make the same xib work as desired on both screens, but I suspect that this is not so easy except for very simple interfaces.
In any case, this is not the end of the story.
Actually, you will not want a "good" app for iPad to have the same UI as the iPhone version, since the larger screen space really screams for using different layout and organization of the information and controls.
As I said, it depends strongly on your app (with games being the strongest exception to the above rule), but in most cases, your app will greatly improve if you redesign it specifically for the iPad, rather than simply adapting it (so that it is not shown in the 1x/2x mode).
The simple answer is yes, just change the device family to Universal and you are done. But this would be pointless and you might even get rejected by Apple.
Take the time to actually create an app that takes advantage of the bigger screen. Use a split view controller and popovers or whatever is appropriate to your app.
Just making your main view bigger is a bad experience for your users.
I am new to iOS development. I am trying to figure out these things.
A project both in iPhone and iPad. what things are same for both (coding, graphics or UI)?
Design Pattern of apps are same or different?
waiting for answer
Thanks :)
Personally, I find that the only real difference between the iPhone and the iPad is the UI and UX. Most of the code is the same for both applications. (In fact, you can even reuse a lot of code if you are doing a universal app!)
The main difference really is the screen size. The iPad is huge in comparison to the iPhone, and this difference gives you a lot more options to work with.
Another thing to note is that the iPad is usually done in landscape orientation, whereas the iPhone is done in portrait. This is not an absolute rule however, it's just the way I see it.
The graphics aren't too different between the devices, except that because of the large screen size, you can do a bit more detailed work with the iPad images then the iPhone images. (Even with the retina display, too fine detail on the iPhone is barely noticeable.)
The other thing I wanted to mention is the flow of the devices. Again, because of the screen size of the iPad, you can fit a lot more content on the screen, and therefore have to push to new views less frequently. I've worked on apps where we had 3 UIViewController's for the iPhone version, and only 1 for the iPad version.
In short, it depends really on your type of app. If you have a lot of content, and want to display it all at once, go for the iPad. If you want a streamlined, minimal approach to your app, go for the iPhone.
Again, this is all just my personal opinion. Hope that Helps!
You can use native controls without much theming and customization on the iPhone. But iPad is a bigger beast. Users use your iPad app for a longer time. iPhone apps are used for a short stint and then closed, used again for a short stint and so on.
Analytics published by Flurry showed that the average time an iPhone app is kept open is about 1.2 minutes. Design and develop it in a way that data is available as fast as you can.
iPad apps are used in a relaxed setting. While I don't have the numbers, it's probably used more often and for a longer time than an iPhone app. Themes and custom UI elements do matter a lot there
Second, iPad apps need to be supported on all orientation (or at least a minimum of two orientations)
I have an iPhone app that I want to change into an iPad app. I do not want to make it universal. The result should be an iPad only app. The main problem I see is converting all of my .xib files. I realize that I will have to change some things around manually, but I would like as much as possible (including all of the painstakingly made connections in IB) to carry over. Also, if there are unlikely places where I need to change settings, please give me a hint to that as well. Thanks!
Xcode has a convert option. It gives you the choice between a new app or a universal one.
This will convert all your NIBs, but quite how useful that is will depend on how thorough you've been with the sizing options in Interface Builder. For me is mostly worked. A couple of minor tweaks for a couple of views and a complete rewrite for some others.
Of course you'll also have to work with view controllers that "manually" build the view.
The gotchas I found were around orientations (iPad apps should work in all four orientations) and with the screen size. There are also some oddities with the keyboard and modal views if you have any of those (there are a few kinds of modal view, and the keyboard does not always dismiss). As ever when you're making automated changes, testing is key.
The full process took me a lot longer than I was expecting.
Few thoughts for changing iPhone app to iPad app.
Xcode has the provision to change the current iPhone app to iPad app by using "Upgrade current target for iPad" menu command.
http://www.enscand.com/roller/enscand/entry/ready_for_ipad
resize all current view to the ipad size 768*1024(portrait) and then resize all the subviews respectively. the connections doesn't get lost by doing this.
I have a question about the objective C. I am writing the iPhone application and I want to app which can also run on iPad. Is there are some change do I need to do? As I set the element in code rather than using the Interface builder. Do I need to reset the x,y,width and height for the application? Thank you very much.
You can run exactly the same app developed for iPhone on the iPad. However, it will not use the full screen of the iPad. Look at the Facebook app for instance, you can zoom it but it doesn't look very nice. If your goal is to run an iPhone app on the iPad, you don't have to bother much. If you want to really support iPad in your application you should implement a separate UI for iPad and this is supported in XCode. The iPad has of course a larger screen but also some additional layouts and controls that make apps look great on the iPad.
Have a look at http://developer.apple.com they have more information about this.