I'm new to iOS programming and is currently following the tutorial at http://codewithchris.com/demo-app-with-xcode-and-interface-builder/
We first create a new project using the Single View Application
library.
Question: About half way into the tutorial, it says Once you have ViewController.xib opened on the left pane and ViewController.m opened on the right pane...
However there is no .xib file anywhere in the Project Navigator, and this is the first mention of an .xib file in the tutorial.
Am I supposed to get a .xib file somewhere along the way? If so, which step will create the .xib?
Select New Project -> Application -> SingleView Application and you will see here . xib file. :) Save this answer.
XIB is an older format of Interface Builder. In newer versions of Xcode, by default, the project is created with a storyboard (Main.storyboard
in your project). The difference is that in storyboards, you can see all the views of your app at once (and transitions between them), and with XIBs you have to keep them separately.
I'm not sure about this (can't check it right now), but if you insist on using XIBs, there should be a checkbox somewhere during creating a project. Anyway, I recommend you getting familiar with the storyboards, they are supposed to be a successor to XIBs.
As I can see in the tutorial, the author says 'XIB' even if he has a storyboard in his project, probably because he got used to XIBs. All in all, they are very similar in usage.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With