Xcode marks a new way of thinking for OS X application development – and for a first release is stable and performs well. With its setup assistant, layout, and searching capabilities, Xcode should appeal to those looking to get started with Mac programming. Experienced programmers – particularly Unix hackers – may find Xcode slow to work with, and lack of vi integration will certainly upset a few.
Min specs: Mac OS X 10.3.
Price when reviewed
Best prices today
Price comparison from over 24,000 stores worldwide
In its quest to make Mac OS X the platform of choice for software developers, Apple has released Xcode, a graphical integrated development environment (IDE) that ships with Panther’s Developer Tools CD. It must be installed separately with the familiar OS X package install routine, and needs to be on the same partition as the system files. Although Xcode will install only on Panther, applications can be developed for previous versions of OS X. Developers will already be aware of OS X’s existing IDE, Project Builder. Surprisingly, Project Builder remains despite the numerous usability and technical features that Xcode brings to the table. As with all IDEs, Xcode features tools designed to remove many of the repetitive tasks involved in writing applications. One of the most apparent is Xcode’s new project assistant that’s launched when New Project is selected from the file menu. It lists all supported language types, including AppleScript, C and Java, as well as an empty project. The assistant comes in handy as it saves a lot of time by setting up the required files and build styles for the application type. Existing Project Builder and CodeWarrior projects are easily imported into Xcode with the import assistant which retains the same project name. Xcode’s interface consists of four main areas: the top panel, which includes the toolbar, search field and status bar; the Groups & Files section, which houses pre-defined Smart Groups and project files; the detail view, where group and file information is shown; and the editor, which displays text. The aim of this interface style is to help coders gain quick access to the files in a project. This works well when using the assistant to begin a project; however, if a raw source-code file is opened with Xcode, the plain editor will launch on its own – which appears out of context. The Smart Groups pane makes navigating the multitude of files in a project easy. This is particularly useful for tracking down file versions or bookmarks. Xcode’s native code editor is hidden by default and must be turned on with the Show Editor button on the toolbar. Coders can jump between functions with the editor’s built-in menu. This navigation menu can be set to show functions in alphabetical order. Of particular use is the editor’s support for dragging a text file from the Finder for it to be displayed. Unlike many IDEs that have tabs for displaying many source-code files simultaneously, Xcode’s editor streamlines this with arrow buttons for jumping from file to file – and a dropdown menu alongside it allows any open file to be selected with the mouse. The 1-Option-Left or Right-arrow key sequence can also be used to switch between open files. Developers coming to the Mac from a Unix background will be pleased to know that Xcode’s default editor can be replaced by emacs or vi. Support for vi is still experimental and results in it being launched externally in a terminal. Additional features of the editor include the ability to automatically complete common code such as function class names. More pre-emptive functionality is present in Xcode’s search tool that, like Finder, will begin displaying results as soon as letters are typed into it. This is very responsive and tracks down lost files quickly.
Usability issues For all its promises, working with Xcode’s interface will take some getting used to. And although Xcode’s preferences has a section dedicated to customizing its keybindings, keep the mouse handy, as a lot of navigation still relies on it. In addition to Xcode’s usability features, the application includes a couple of tools to help decrease the amount of time spent compiling code. Xcode’s predictive compile feature – which isn’t enabled by default – uses the GCC compiler to start compiling as you’re editing your code. For further speed improvement, the Rendezvous-enabled Xcode can use more than one computer on a network to compile a job. Another text editor for OS X, Hydra, uses Rendezvous for collaborative editing, so keep an eye out for additional applications of this technology by Xcode. Recognizing the fact that all developers – experienced or not – require some form of documentation, Apple has developed a documentation system for Xcode. Documentation is a blessing when you need to know the specifics of a function method; however, it’s launched as a separate window and would be easier to navigate as part of the main interface. Nevertheless, being able to quickly search through the documentation is very helpful. Another tool that is separate to Xcode’s main interface is Debug, the code debugger. Being based on the mature GNU debugger, Debug performs as expected, but like Xcode’s documentation, hasn’t been integrated into the main interface – it requires an additional window. Like all IDEs, Xcode will help you speed up application development, but it won’t go very far with helping you learn how to code. Books and other reference materials are good places to start, as well as reading the code from various open-source projects. A selection of open-source applications for OS X can be found at Freshmeat’s OS X section – http://osx.freshmeat.net.
Important Xcode update With OS X users used to regular software updates, it comes as no surprise that the first update to Xcode, version 1.0.1, has emanated from Apple. Critically, this update claims to addresses an issue that may result in data corruption or the loss of files. It goes without saying that all Xcode users should perform the upgrade.