Developer Tools • 43:15
Mac OS X provides a comprehensive set of developer tools, with Leopard introducing several new ones. Find out where to begin, from the basics of navigating the Xcode development environment, to user interface design with Interface Builder, to runtime analysis with Xray. You will learn how to put it all together so you can start creating the next great Mac application.
Speakers: Todd Fernandez, Anders Bertelrud
Unlisted on Apple Developer site
Transcript
This transcript has potential transcription errors. We are working on an improved version.
Good morning and welcome to Session 301 getting started with Mac OS X Development Tools. I'm Todd Fernandez, and I manage the engineering teams which create Apple's IDEs, otherwise known as integrated development environments. So it's early, let's get started with a little audience participation. How many of you are new to developing on Mac OS X? Whew. Good, I came to the right room this morning. Excellent.
Well, we in the development tools organization and everyone at Apple, are really excited that you're here with us this week and want to create great products for and on the Mac and to help you get started, we have a number of important objectives today for this session. The first is to introduce you to the breadth and depth of our Apple Developer Tool Suite and as we do so to point out the comparisons and contrasts with some of the other tool suites which you may be familiar with on the platforms you already work on.
We want to make sure that you understand what task each tool is particularly well-suited for and, finally, we know that conferences like these can be overwhelming and it can be easy to end up spending time inefficiently, you've made a big investment to be here this week, and I want to help you make the most of it by providing guidance on which sessions will be most useful to you.
So, we're -- we're all developers here, right? Okay. We know what developers do; we edit our source code; we search and read documentation; we build our products; we test them, ideally. For those of you who put bugs in your code, we debug them. We analyze and tune their performance to give our users the best experience possible. We package them up and then we deliver them to our adoring fans otherwise known as our customers if we've done the testing and debugging part correctly.
So you already have a workflow and a set of tools that you use to do these tasks already wherever you may be coming from and whether your tools are platform agnostic or tailored to a particular platform, you already have a workflow and a set of tools that you -- you work with every day. Well, we have a great set of tools on Mac OS X too, the Xcode tools. And while they may be tailored to creating native Mac applications, they are also great at building lots of other types of products.
So whatever it is that you like to build, we have the tools for you. So to get you oriented let's take a brief high-level tour before we get into the details to show you what -- just get you oriented. This, in fact, is a stylized version of what you might see if you install the Leopard preview that you received yesterday in the Developer Applications folder. So let's start right at the top with Xcode; our universal IDE. This is where most of you will spend the majority of your time editing source code, reading documentation, building your products and debugging them.
Interface Builder is our interface design tool, and it makes it really easy to build beautiful user interfaces and connect them up to your source code implementation. It also provides you a lot of guidance to make your user interface match the Apple Human Interface Guidelines so that your application looks great on the Mac. Dashcode is another IDE that's focused on widget development, and it makes it really fun to build beautiful widgets.
It gives you all the user interface elements and source codes snippets that you need to get started, and it's also new in Leopard. Xray is another great new tool that's new in Leopard that is an analysis tool that allows you to -- it uses the kind of the concept of GarageBand to allow you to assemble instruments and record data on your program's performance along a timeline allowing you to correlate all sorts of different types of information about your program's behavior to analyze and optimize its performance.
It also includes a UI recording feature that allows you to playback over several times with different instruments a particular scenario that you're debugging, and we'll talk about it more later. We also have a number of more specialized utilities whether you're making your application more accessible for those with disabilities.
Whether you're building a plug-in to take advantage of our synchronization technology, iSync, to synchronize your program's data files for your users or debug it with Syncrospector whether you need to build a custom package for your -- to install your product with PackageMaker or perhaps perform more prosaic programming tasks like editing property lists with Property List Editor or comparing two source files with FileMerge, we have lots of great utilities to help you.
Next I'd like to talk a little bit about graphics tools. Quartz Composer is a great tool that allows you to create different types of motion graphics for integration into all sorts of different applications, and we'll talk more about that later on. OpenGL Shader Builder is a great tool for building vertex and fragment programs for the GPU, and we'll talk more about that later on as well and Core Image Fun House allows you to explore the Core Image Framework to make your application's graphics look really great.
So moving on to performance tools we've already talked about Xray. We have a number of other great performance tools starting with Shark which is more in the instruction level, and we'll talk more about that more later as well. I also want to highlight Quartz Debug which among other things allows you to set the user interface resolution scaling factor to ensure that your application looks great at higher resolutions. I want to highlight ObjectAlloc and Sampler which prior to Leopard were independent tools but have now been incorporated into Xray so that you can take advantage of their functionality, again, in that integrated way and correlate it with other types of data.
So that's our initial tour to kind of get you oriented and to move on further I'm going to ask Anders Bertelrud to come up and talk about how to use our Toolchain to build native Mac applications. So, please welcome Anders.
( Applause )
Thank you, Todd. Okay. Great so we're going to talk about creating native application using Xcode. As Todd mentioned Xcode is the central development IDE hub on Mac OS X, this is where you'll spend most of your time doing Mac OS X development.
So what can you build with Xcode? Well, native applications, what do I mean by that that means Cocoa, Carbon applications, applications designed specifically for Mac OS X using the Aqua User Interface those kinds of things, but Xcode is also great for open source projects. If you saw the talk yesterday where the organizer was showing there's a new feature in Xcode designed specifically to work with open source projects that maybe have a different build system than native Xcode one, code bases that can be built for multiple platforms, you may be bringing some of that over onto Mac OS X, maybe putting an native interface on that and using that open source as part of your project.
You can, of course, also build other kinds of projects like kernel extensions. You may be doing image unit plug-ins, you might want to do a plug-in for a specific application such as Photoshop, those kinds of things. You can do that with Mac OS X as well -- with Xcode as well.
We're going to focus on native applications just take you through a workflow here and as I go through the workflow I'm going to just show a series of screen shots and describe what's going on, and then we'll give you pointers to sessions where you can go and see much more detail about the particular topic that interests you.
So creating a new project in Xcode is pretty easy. Xcode has a wide variety of project templates to get you started. You see here -- if you can read that, you see there's a lot of different kinds of application templates. The most common thing is to create a Macintosh application that the user can double click and can run as a menu bar but there's also all kinds of other templates for whatever you want to do. Maybe you want to create one of these little preview plug-ins that were shown in the keynote where you can actually see the contents of your document right there in the finder. There's all kinds of plug-ins.
So, when you create a new project, you see the Xcode Project Window and as you can see it's already populated for you with all kinds of information and, in fact, it can -- it can - you can build and run it as it is and get a standard application and then, of course, you fill in your parts. So I just want to take you through the contents of the Project Window here, there's obviously source code files. We list those that's regular Objective-C or C any -- any language that you have compiled for.
User interface files as Todd mentioned we have a great tool called Interface Builder that allows you to create UI for your application; we'll talk about that in a minute. But those files are included in an Xcode project so Xcode project references all those and organizes them together. There's also Data Model Files so just like your user interface is a structure of UI elements, we have data modeled files as well.
I'll show that in a minute also there are other resource files, in this case we see a couple of string files a couple of other localized files. Mac OS X has great localization features so you can very easily take all of your human readable strings and other UI elements and localize them into a variety of different languages.
It's all dynamics so your one application package can contain many, many different localizations and then the users can switch on the fly and, in fact, different users on the same machine can choose to see different languages. So you can have all these other resources in various localizations in your Xcode project.
So those are the building blocks, the parts, from which you build your project, your application or plug-in whatever it is and targets are the instructions. It's like these -- this furniture that comes in the package, right, you have all the various parts and then you have the big sheet that labels everything and says how to put everything together.
In Xcode those are the targets, in an open source project that might be a Makefile or an Ant file if you're doing Java development. So in our case it's the targets that contain all the instructions and the little details about how to put all these pieces together and Xcode also let's you define execution environments for your -- your app and what do I mean by that, well, there's various ways you can run your program.
You might want to run with certain debug settings. You might want to run it with a certain performance tool or you might want to set it up to open some test documents automatically, so you can set up a bunch of those in an Xcode and very quickly test your app in various scenarios.
So, for more about the details of this, we have a great session called Getting Started with Xcode and that's actually in this room right after this session so... So one of the most common things you would do in Xcode besides organizing all the input files is to actually edit your source code because that's what contains all your custom logic for -- for the app and as you might have seen yesterday we have a great embedded Source Editor that's very powerful and also contains a lot of features to let you focus on the code sort of eyes on the code principle.
So as you see here there's a warning message that's shown in yellow here that's shown right below the line that has the warning there's also in this case we see a debugging tool tip that shows you -- not only shows you the value but you can actually edit the value, evaluate expressions, those kinds of things and you can set break points right there in the gutter, what we call the gutter, and you can also enable various other features, the line numbers, all kinds of things. For more about the new sort of editor-centric development workflow in Xcode 3.0, we have another session on that, that's 305, session 305 that's tomorrow in the Presidio.
I mention Interface Builder, you edit through logic in the Source Code Editor but you use the separate Interface Builder tool which is very tightly integrated with Xcode so you might have seen a demo yesterday where a simple context click can open up a corresponding interface file in the Interface Builder.
Interface Builder works a little bit differently from some of the tools on other -- other platforms that generate code. Interface Builder does not generate code for your UI. It actually keeps a rich, well-connected representation of your user interface elements and the connections between them and this is great over time because it's a lot more maintainable then generating a bunch of code that you then have to understand and modify. So it's actually an object archive of your UI elements and of the connections between them and something called bindings which is a connection between the UI elements and the fundamental properties of the objects in your program.
There's a session on Interface Builder tomorrow in the Mission Room, and they'll be showing some of the great features of the new Interface Builder in Xcode 3.0 which includes the library -- parts library and also very good Aqua guides for creating really high quality Aqua User Interfaces. So similar to how we have a hierarchy of User Interface Elements that are well connected and editable over time, Xcode also has a Data Model Editor that actually does the same thing really for your objects, your -- for your fundamental object graph. So these are the objects that are underneath your UI that represent your actual data set.
So, if you're doing an address book application, you might imagine you have a person, records, you have groups, you have these kinds of objects and you can code all that by hand, but it's a lot easier to lay that out and to develop that as a connected graph of objects and classes and here again Xcode maintains this as a strongly connected representation and uses Core Data underneath the hood to let you do a lot of these things without actually writing any code so that's a great timesaver.
There's a session on that too, Core Data session which would be actually today It's following this session in a different room in the Russian Hill -- hard to go to both, so part of this session is to help you choose which is going to be the most appropriate for you and make sure you're seeing the right -- the right presentations.
So we've taken a look at a couple of different screen shots in terms of workflow for using Xcode to build the native app what we've done here -- well, part of what we're doing is to use Code and User Interface and Data Model Editors together and the language the primary language, Objective-C, is a very dynamic language and the frameworks and tools take great advantage of that and actually -- you can actually use Ruby or Python or some of the other scripting languages which are also very dynamic to do the coding part.
So there's dynamism in the Cocoa frameworks, there's dynamism in the language and the tools and there is a common paradigms used throughout the stack and one of those is Model-View-Controller that many of you may be familiar with and that's where you quite simply separate out your Data Model which has nothing to do with your user interface and then you have your view layer up at the top which is edited with Interface Builder and then in between those are the controller layer.
One of the great things about Mac OS X is that there is technology called bindings which let's you really drastically reduce the amount of code you write for the controller layer so that, if you want a button to enable or disable based on the state of some model object, you can easily do that in Interface Builder, just set-up the connection.
You don't write a single line of code the properties of the UI elements will -- will take their values from the corresponding properties in the model and vice versa so that, when you enter something in the UI, it automatically affects the model. There's also integration with Core Data which is this great technology for building up your data model.
So the tools and the frameworks and the language all fit together and this is a bit similar to some of the other platforms you may be familiar with Visual Studio and C Sharp and .NET where those three things kind of work together. On Mac OS X we have the same thing Xcode, Cocoa and Objective-C, but it's very dynamic and it really -- it really let's you kind of shift into another gear in terms of development.
So one of the examples of the integration here is the refactoring feature in Xcode. It's actually new in 3.0 so let's take a look at that -- oh, I should say, yes there's a session on getting started with Cocoa Bindings that's going to be later on today, not at the same time as the 10:30 one.
So refactoring what is that, well, refactoring in general is to make whole program modifications to your code while preserving the semantics and Xcode let's you do that you can, for example, extract a little piece of a function or a method into another one, you can rename something across your whole program and preserve the semantics. We actually go a little bit beyond that too you might have heard the Objective-C 2.0 which is new in Leopard. It's garbage collected, it has iterate support for iteration those kinds of things.
It's a newer edition of the language that you can opt in to. In addition to the refactoring operations that preserve the semantics entirely, we also let you do whole program transformations that may go beyond that and modify the semantics to something that you want, to make it garbage collected, for example.
So we have refactoring operations to adopt some of the Objective C-2.0 paradigms. In this case we see an example of the integration, this is an example of doing a simple rename refactoring, but you notice that not only the source code is being named but also the nib files, these Interface Builder files.
So Xcode can index and it knows about your Data Model Files, and it knows about your UI files and then, when you make changes, it goes across all those and make, make the changes correspondingly. So here we see the difference here in terms of the structure of a UI element file the Interface Builder File and that it's kind of reached in there and modified the -- modified the attributes.
You'll notice there's a checkbox here. I don't know if you can read it in the back; it says snapshot and what this is is whenever you make a whole program transformation, you probably want to take a snapshot of the state of your project so this means that if you decide later that you did something that you didn't really want you can rollback to that and that will be talked about more, refactoring and snapshots, in the special session on that and that is actually on Thursday in the Presidio Session 312, all of these are listed in your schedule as well.
So, once I've taken a snapshot and I've decided that it wasn't such a good idea to rename it, I can actually restore from a snapshot and these snapshots just stay around and you can decide when you want to delete them but by default they just kind of build up a history of the different states that you moved through in your project, and it makes it very easy to see what changes you made even to Data Model Files and UI Element files not just your source code and you can easily roll back or just restore a particular change.
So those are all about editing and modifying the parts that go into your project. Talked about targets that are the blueprints that are these instruction sheets for how Xcode should actually assemble all these things together. So a target consists of a variety of different parts itself. It's very flexible. You can use a target to copy headers.
You would do that, for example, into a framework. A framework on Mac OS X contains both a code and resources and the APIs in terms of headers that are accessible. There's obviously resource files, you may have something like a framework that has UI functionality and it may have Interface Builder files in and of itself in there or actually Core Data model files might be in there.
There's a facility you can run, actually, an arbitrary script. You can run Shell scripts, Ruby scripts any of those kinds of things as part of your build, this can be very powerful because it gives you hooks such that you can evoke even an entire rebuild system if you want to but more commonly people will just run some custom tool.
You can even set-up your projects so that one of your targets builds a custom tool that converts let's say an image into some custom format and then a later target can actually evoke that tool and then perform that transformation on the resources for your application. So very powerful and something that really, really let's you do almost anything as part of the build.
There's obviously the code that's in your projects most -- most interesting projects contain some custom logic, so Xcode will compile and link that code for you and there is like the project template there is a variety of different target templates for you to choose from all the way from Carbon and Cocoa, UI stuff even if you just want to create a command line tool you can easily do that with the starting point templates. There's another session called 311 about the Xcode build system and that one is on Wednesday. And there they're going into a lot more detail about how to customize the build system.
So you've edited all your files; you've built your project and then, of course, you want to run and debug and Xcodes' debugging is pretty powerful. You have a debugger window that you can just really immerse yourself in if you want to but in general we want to keep the eyes on the code. This screen shot shows the debugging window that you might not have seen in the previous sessions typical thing with the stack trace and showing the various variables, of course, you can evaluate expressions on the fly you can modify expressions, modify the value variables. You can actually drag the program counter back in time and rerun a piece of code over again after you've modified a value those kinds of things that can really help you -- help you figure out what's going on.
( Inaudible audience question ) There's some support for that. I think it's probably best to go to the debugging session and ask that question -- oh, sorry. In general, if we could ask the questions at the end, that would be great. We're actually going to have a Q&A session at the end of this, so we will -- we'll remention that question then.
Unit testing is a pretty powerful thing that's in Xcode and the idea here is that your software is composed of various components that can be tested in isolation. So you may have a little tool box or you may even have just a class with some kind of data structure where you can test it outside of its use in your app and what you can do in Xcode is set up Unit tests for that component and there are several benefits to this.
One of the benefits obviously is that it helps you develop your API and make sure that that component is well designed but also over time as you optimize or make changes to the component it actually helps you make sure you didn't change your semantics inadvertently, and you can easily set-up Xcode to run all of these unit tests whenever you build your project.
And this is great, this example shows, for example, that I just intentionally in this case introduced a semantic change in one of my components and because these unit tests are all run all the time, if you choose, you can easily see as soon as you made that change and then you can debug that and step into it and see what caused the change maybe you tried to optimize something but you forgot about some edge case. So in summary about Xcode we have tools; we have the language; and the frameworks that work very well together, Xcode, Cocoa, Objective-C are the tools framework and language, and they're really designed together to make you more productive and all of them are improved in Leopard.
So you've built your app. You're running it; maybe now you've debugged it, tested it, and now it works well but maybe it's running a bit slow, maybe it's using too much memory, so like Xcode is the hub for development, Xray is really the first starting point for analysis.
So what is Xray, what can it help you analyze? Well, obviously memory usage that's the big thing. It's often related to the performance because, if you use lots and lots of memory, your machine is probably going to slow to a crawl. CPU performance if you are doing numeric calculations just raw -- raw performance there but there's all kinds of other stuff maybe you're interested in, you know, why is this file being opened 10 times, what in my code is doing that. There's network activity and specialized graphics calls and really with Xray almost any behavior of the application can be analyzed.
There are great starting point templates, you might have seen this panel before. This is what you see when you first launch Xray and you can start with either one of those commonly encountered analysis templates or you can start with a blank one and drag in your own instruments from the part library. Just a quick overview of the Xray window as you can guess I'm going to refer you to an Xray session here for the details.
But the basic idea is that it is a collection of instruments and you can add as many of those as you want and then, once you've collected data, all these data streams are collected together so that you can correlate them over time and that's a really powerful thing so, once you've done that, you can see your data in various ways, there's all kinds of options that are based on the selected instrument.
There is a list of trace events for the selected instrument for a sampling instrument this would be, you know, what was the stack at any given time; for an allocation instrument; it might be well what -- what's the actual object allocation so that's the detail there at the bottom for the instrument you have selected and there's an extended detail of you that usually shows you the stack trace of an extended selected trace event so you can see exactly where any given block of memory was allocated where a particular file was open, those kinds of things. There is another session on Xray. It's in the Presidio on Wednesday and that's a great session that will really give you introduction to how -- how to use the power of Xray.
So one of the powerful things about Xray that is kind of new is the ability to add an arbitrary set of instruments and collect all these things over time. Very often you'll find -- you'll be running your tests and then discover that, well, now I understand that it's doing a certain thing but now I need to add another instrument to know why and what you can do is you can develop your own templates, if you want to, you can customize and save off your own templates and in particular what's really useful is you can actually add one instrument that records the UI actions that you performed and you can play those back and this is great for when you say, well, let me see what the CPU is doing and then you discover, well, okay, now I know what the CPU was doing but was I opening any files at the time. You can just go back and add that instrument in and then rerun your test and Xray will rerun exactly the same UI actions that you performed and you can see exactly what's going on with this other instrument -- really powerful.
So once you have your data you, of course, want to see what's going on there. You can narrow down the scope onto just the timeline that you want to see and, of course, one of the interesting things is to see it what line of code -- of my code was causing this, so as you may have seen of the demo yesterday you can go directly from a back trace back to the line of source code in Xcode.
So in summary it's really a way to gather all these different tools that Apple has had for a long time for analyzing your program's behavior; do it in a nice intuitive user interface based on the GarageBand metaphor and to be able to capture data streams and those kinds of things and it's compatible with lower level tools like Sample, these old -- older tools Xray can open those traces and really show you everything in one unified front end. So we've seen just a brief overview of what it looks like to create a native application and to analyze it using Xcode and Todd's going to come back on stage and show you what else you can build with Xcode.
( Applause )
- So buckle your seatbelts, we're going to continue on with kind of a whirlwind tour of a sampling of the variety of other types of products and other types of tasks you can perform with the -
- the diversity of tools on Mac OS X; first starting with what else can Xcode build? This is obviously in order of importance but you can build screen saver plug-ins and integrate great content that you create using Quartz Composer which, again, I'll talk a little bit more about in a moment and there's a Quartz Composer session about how to use it to design your motion graphics tomorrow morning.
Next project particularly dear to my heart, Automator Actions for those of you not aware of Automator it's a great end user level automation tool and what we have seen is that, if you build a well-designed set of Automator actions for your application, you can expose its power and it's functionality to a much wider audience and sell more copies of your software and, if you make it really easy for your customers to integrate your application into an automated workflow, they're going to be loyal customers. They will not want to go back to doing that task by hand and there's a great hands-on session tomorrow morning. It's a popular time on how to build Automator actions.
Something else really fun, games: Mac OS X includes industry standards frameworks like OpenGL, OpenAL, GLUT that makes it easy to bring your platform agnostic code over to Mac OS X and put a beautiful Cocoa user interface on top of it, and we have sessions on bringing your OpenGL Code over to Mac OS X. What else can we build, well, perhaps the polar opposite of games, if you need to build I/O Kit Drivers or other types of kernel extensions, Xcode makes it easy to do that as well and, if you need to know how to do this or already know and just need some additional tips and tricks, we have a session immediately following this one on kernel debugging.
So one of the things that Anders has mentioned several times already is that particularly in Leopard this has been possible before but there's a lot of great new functionality in Leopard that makes it much easier to build native Mac OS X applications using your scripting language of choice.
Historically you've been able to do that with our own scripting language, AppleScript, but we have also bundled the bridges that you need to build your applications using Python or Ruby and that's all really easy to do in Xcode as well, support syntax coloring and the other important editor features right in Xcode for those languages and there's an entire session on that Thursday morning on how to develop Cocoa applications using Python and Ruby.
Moving along on our whirlwind tour, again, Anders mentioned open source projects earlier and there's a great new Xcode feature called the Organizer which you may have seen in yesterday's developer tools State of the Union session that makes it really easy to bring over projects that don't use -- that aren't Xcode projects and use other build systems like Make or Autocom for Ant. The Organizer makes it really easy to just drag those projects in.
It will automatically detect that your project uses one of those build systems and set-up the build, clean and run buttons for you. You can also integrate all sorts of other type of scripting into the action menu and customize your -- your -- the Organizer to your heart's content so it builds and works just the way you like it, and there's a complete session on that, hands-on, so you can follow along with the presenter on Thursday afternoon.
So, that's, again, a whirlwind tour of other types of products that you can build with Xcode. Let's look at some of the other tools that we have for other types of projects. So I just refer to the Organizer and the fact that it can -- it supports the Ant Build System which makes it really easy to work with Java Projects and Mac OS X is a really great Java development platform. How do I know that because we see the seeds of MacBook Pros in Java conferences and we have a number of sessions this week about bringing your Java applications to Mac OS X Leopard.
So perhaps a diversion -- so how many out there think that this whole GUI thing is a fad and it's not going to last, prefer to just be working with vi and Emacs in a terminal? I -- I sympathize, and we have tools for you as well, both specialized tools like Xcode Build which allows you to build your Xcode project at the command line and Xed which is a great new tool in Leopard which allows you to open up the Xcode Editor from the command line and integrate Xcode into your -- allow you to script these tools and interact with them from terminal, plus we have the other command line tools that you'd expect on any Linux -- oh, Linux, UNIX platform, wow, including our Compiler GCC and the other tools you might expect and for those of you who don't know what these tools are, you don't need to, the GUI tools will take care of it for you but those of you who do love these tools, they're there for your use and there's a session on compiler advances that we've made in GCC for our purposes on the Mac on Thursday afternoon.
So we've mentioned Shark earlier. Xray is a great new performance analysis tool on Leopard, Shark has been around later -- ah, longer but it has a great new version in Leopard, and it focuses more on instruction level analysis. It is great at helping you find hot spots and highly optimized algorithms.
You can use it to take profiles of your application or the entire system to see what kinds of interactions are taking place between your application and all the other processes on the system and this can be great for tackling all sorts of problems like those that are listed on the slide which I'm not going to read to you. Some of you may have encountered these problems before and Shark is a really great tool for helping you solve them.
This is a screen shot of a Shark time profile of one particular application and you can take similar profiles of, again, the entire system that tell you exactly where the time is being spent. And there's a session on Thursday afternoon about getting started using Shark to analyze and optimize your code.
So, again, let's drop back to the terminal, we have a number of analysis tools that are also accessible, again, including specialized tools that are specific to the Mac like a command line tool for Xray that allows you to take the data which you can then later analyze using the GUI, DTrace which is great open source technology that many of the Xray instruments rely on you can also, of course, access from the command line; Sample is a great tool for sampling a performance of your application periodically pausing it every ten milliseconds and finding out where it's spending its time but Sample, again, has been also incorporated in Xray.
Shark we have a command line tool to take the Shark Profiles which you can then later analyze with the GUI and a number of other tools that you -- many of which you will find familiar from other UNIX platforms to look at in various ways at how your program is using memory use -- using memory and how you can optimize it to give your users a better experience with your application And we have a session on using DTrace which, again, will be great for those of you who -- not these newfangled GUI's on Thursday afternoon.
So how many of you are familiar with installing your application on other platforms, how many of you have dealt with that? Installation is lot similar -- simpler on Mac OS X. In many cases it can be as easy as building a disc image with your application bundle and just allowing your users to drag it over into their applications folder. That's it. The bundle technology on Mac OS X allows you to include all kinds of associated data that the operating system can then find in the bundle like document icons and other kinds of associations so that the operating system shows that it knows your application is there without you having to do anything with registry keys.
The operating system takes care of that for you but, of course, if you have more complex installation needs, we have a great tool called PackageMaker which allows you to build custom installers that allow you to do pre and postinstallation scripts and all the other bells and whistles that you might need if you need to install other things on the system and this is just a -- a look at it; allows you to graphically lay out your welcome screen and provide the look you want; your license agreement whatever else you need in your custom installer and then there's a session on that later this afternoon in this very room.
So continuing on with our tour we've referenced Quartz Composer several times. It's a great tool for designing motion graphics which you might not think about but can really be quite powerful in a lot of different types of applications, not just screen savers as I mentioned before. Quartz Composers animations are actually used in a wide variety of applications on Mac OS X from iTunes to Dashcode to screen savers and you might find it very interesting to add some more visual pizzazz to your application so I encourage you to come out to one of the sessions to find out what you can do with Quartz Composer tomorrow and Thursday, again, in this very room another very interesting graphics app is OpenGL Shader Builder which I mentioned earlier, and it's a dedicated tool that allows you to build your vertex and fragment GPU programs for OpenGL and test and debug them. And there's a great session on tuning your application on Thursday morning, which brings me to Dashcode, another project particularly near and dear to my heart which you may have seen shown yesterday.
It's an IDE focussed on building widgets which are a lot of fun and it makes -- Dashcode makes building widgets really fun. You can start off with a variety of templates. You can see that we have a similar concept in many of our development tools from Xray, to Xcode, to Dashcode where we provide you rich starting points to get you going. You can create all sorts of different types of widgets, edit them graphically, we have the DOM there on the left navigator to make it easy to select different portions of your widget's interface, steps which actually lead you through the whole process of building a widget.
The parts library, again, similar to Interface Builder and Xray where we have a library that allows you to drag in instruments in Xray or different user interface elements here in Dashcode as well as Interface Builder and an Inspector to customize those parts to look just the way -- look and behave just the way you want them to. It also has an integrated editor which makes it very easy to edit your JavaScript CSS and HTML source that makes your widget.
There it is and it is very similar to the editor in Xcode. It gives you the same syntax coloring and code completion that you would expect. We also have a Files View which allows you to manage the files that make up your widget and, again, in the library we have also reasonable code snippets, little pieces of JavaScript code that -- for common tasks that you might need to implement your widget, and finally we have an integrated JavaScript debugger as well with the controls you'd expect to step through your code, examine the variables and the stack frame and easily see your running widget as you're stepping through your code and debugging it, and we have a great session -- I know because I've been in the rehearsals -- tomorrow afternoon in this very room, popular room, and I hope to see you there and that concludes our whirlwind tour of tools on Mac OS X. But let's refresh our memory, again, to keep us all oriented, so again Xcode is our universal IDE where you're going to spend the bulk of your time for most products; Interface Builder where you're going to build your user interfaces for your products; Dashcode where you can build a great widget that can help promote your products and give your users a really quick experience if you to enter some data for your particular application; Xray is a great new application makes it really easy and fun to analyze your programs's behavior and find performance and memory usage problems.
These are our tools, again, this is what you'll see when you install the Leopard preview that you received yesterday which I'll highlight right there on the DVD, you can open up the installer and install the tools. One of the great things about Mac OS X is that each release includes the latest and greatest tools, tools aren't an afterthought, they're part of every release of Mac OS X but what about in between releasees? Well, we often have tools releases in between OS releases and you can easily down load them from the ADC web site at developer.apple.com/tools. So to sum up, again, as Anders mentioned earlier Xray is really the hub of the development experience on Mac OS X, but Mac OS X also has all the other tools you need for specialized purposes and other types of products.
We encourage you to use our powerful analysis tools to polish your software and make it run really great on the Mac, and please take advantage of the many detailed sessions; those we've highlighted today and there are many others as well that we didn't have time to point out and have a great conference.
We're really happy to see you here and we look forward to what you build with our tools, go out and amaze us. Matthew Formica is our evangelist and, if you have any questions about tools, he's a great contact and, in fact, he'll be giving the Getting Started with Xcode session immediately following this one.