Learning more about the User Interface [iPhone Development]

iPhone Development

Something was done!

I’ve currently kept myself a bit busy with the Beginning iPhone 3 Development: Exploring the iPhone SDKbook and if you checked out my iPhone Development Flickr Set you could see some progress as I go. (I currently have my development of a game paused for a second, since I got asked to do something for someone. I’ll talk about this later)

Like I mentioned before, I plan on writing a review once I’m further into the book, but I wanted to stop by and discuss with you some of my progress. It’s not going to be in a lot of detail, but enough for you to understand.

So far I’ve learned the basic development process for making an application. You fire up Xcode and start with a simple template. For example, I created an instance of a string and a button variable within the code. Then I create a function that changes the value of the string when the button’s value has changed. I then fire up Interface Builder. (Below is what it looked like for this project. The image has transparency so disregard the way it looks for now.)


interfacebuilder

Interface Builder is like a carpenters tool belt since it has all the tools you’d possible need to make an application. I start by simply reaching over at the Library to pick a label and a button so I could place them into my view. I then can edit their default values if I wish among a myriad of other properties using the Inspector.

Now, the interesting part happens. In order to connect the code found in Xcode to Interface Builder, I simply make a connection between the code, happens to be an icon provided to me (“Files Owner”), and the respective object, label or button. I then have the ability to associate this object either with an action (function) or a variable. These connections make my code react to the objects placed in the view depending on the actions of the user.

Then, I simply build and compile and test my application from within the iPhone Simulator. Yes, its as easy as it sounds but of course, there are a couple of things I left out that you would take care of if you tried it for yourself.

Tags: ,

  • http://twitter.com/junwangucr Jun wang

    I love this post, very useful!!! Thank you!!!