iPhone Freshers and live Project training
By TOPS Technologies….
How To Make iPhone Apps –– An XCode 5
How To Make iPhone Apps An XCode 5
1. Where Can You Download XCode?
The easiest way to get XCode is through the Mac App Store Click the
link to go to the listing.
You can also download it manually if you don’t have the Mac App
Store. Just visit the Apple Developer Page for Xcode.
2. Demystifying The XCode Interface
The diagram below is from the Apple Documentation for Xcode.If your interface
looks different, make sure you have XCode 5 and not an earlier version.
The reason this is a great diagram is because it lets me refer to these different
sections of the interface and you can refer back to this diagram to see what I’m
As you can see from the diagram, there are 4 major areas: the Navigator, Editor,
Debug Area and Utility Area.
Keep in mind that you can adjust the size of each of those panes by hovering your
cursor over the boundaries of each area and dragging.
◦ This is where you’ll see all the files associated with your project.
You can also right click on the project navigator and create new files or add existing
files to your project. Or you can drag folders or files from your computer directly
onto the project navigator and will popup a dialog asking how you want to add the
If you click on a file in the project navigator, it will display the file’s contents in the
Editor area. If you double click a file instead, it will open a new window which can be
useful when you have dual monitors.
With the search navigator tab, you can easily look for pieces of text in your project.
The issue navigator shows you all the problems with your app.
The editor area is where we’ll probably be spending most of our time! This
is where all the coding happens.
There are these little back and forward arrows in the upper left corner of the editor
area. Unfortunately these arrows aren’t labeled in the trusty XCode interface
diagram at the beginning of this article so I’ll call them “XCode back and forward
arrows” and show you an image of them here:
These guys are actually pretty useful. They act like the back and forward buttons
on your browser and they let you navigate to previously viewed files.
Three types of editor views
The editor area has three different views and you can toggle between them with
the set of buttons in the upper right hand corner:
Interface Builder View
So far we’ve been talking about editing code files and writing code, however XCode
has interface builder integrated in and when you’re viewing the Storyboard or a XIB
file, the editor area will turn into a visual designer.
Finding and replacing within the file
Just hit Command-F to bring up a search popup in the upper right corner that will
look for whatever you type in within the current file. This is also a great way to jump
to various areas of your file. You can also use this popup to do replacements within
Jumping to definitions
If you’re looking at some code and you see a classname that you want to jump to
the definition of, you can hold down Command and click the classname to quickly
jump to that file.
The XCode utility area is comprised of two
panes: the inspector pane and the library
The Inspector pane will give you details about the file you’ve got highlighted in your
project navigator. However, when you’re looking at a XIB file, the inspector pane will
show you the different attributes that you can modify for a selected element.
The library pane won’t be very useful either until you’re looking at a XIB file. When
you’re using the Interface Builder part of XCode, you can drag UI elements from the
library pane onto the editor area to add that element to your user interface.
The debug area will show you console output and the state of various
variables when you run your application.
You’ll be using this a lot while debugging your code and trying to figure out
why things aren’t working out the way you expect them to! I’ll need to write
a separate XCode debugger tutorial because there’s too much to mention
We’ve talked about some of the buttons on this tool bar already. Let’s start
from the left.
The left-most button is the run button. This will build and run your
application and launch your app in the iOS Simulator. The button beside it
will stop the execution of your application and return you to XCode.
If you click and hold down the Run button, you’ll get more options to run
The Organizer button on the far right of the toolbar brings up a separate
window called the Organizer. There are several different purposes of the
organizer and we’ll highlight them below.
There are a lot of things you can do in the devices tab that I can list them
all. However, the main uses are to manage your provisioning profiles on
your system AND on various devices.
We haven’t talked about provisioning profiles yet, but they’re important for
deploying your app on actual physical iOS devices. I’ll need to create a separate
tutorial for that.
You can look at crash log from devices, enable development use for various
connected devices and more.
This only applies to XCode 4.
In XCode 5, Repositories are now managed in XCode->Preferences>Accounts
In the repositories tab, you’ll be able to manage local and remote repos that you
have set up for your projects.
In the projects tab, you can see a list of projects you’ve opened before so you
can quickly open them again and you’ll be able to manage derived data and
snapshots of your projects as well.
In the archives tab, you can manage your archives for various projects. You
would archive your app when you want to deploy it to the store or distribute it in
some other manner.
This is only for XCode 4.
In XCode 5, Repositories are now managed in XCode->Preferences>Downloads
You can view various iOS SDK
XCode 5 comes bundled with a wonderful iOS Simulator for you to test your
application on. In fact, you can use the iOS simulator for most of your development
and then find a device to test on when you’re nearly done.
You can actually do a lot with the simulator including:
-Simulating various GPS coordinates
-Simulating low memory scenarios
If you want to test various network or low bandwidth conditions, there’s a tool called
Charles Proxy that works brilliantly.
Contact Us For iPhone Training
Contact Us For iPhone Training
College Students from Ahmedabad Gujarat BCA, MCA, BE IT, BE/B.Tech,
ME/M.Tech, BSC IT can also join.
Ahmedabad Office (C G Road)
Ahmedabad Office (C.G Road)
903 Samedh Complex,
Next to Associated Petrol Pump,
Ahmedabad Office (Maninagar)
401 Amruta Arcade 4th Floor,
Maninagar Char Rasta, Nr Rly Station