Blog Action Day

First Compiled GUI App

0 #

This is a post in my series “Road to Xcode.” I am currently reading Become An Xcoder by Bert Altenburg, Alex Clarke and Philippe Mougin.

08: A Program With a GUI

I compiled my first example application with a GUI, which consisted of tracking down a self inflicted bug. It is expected for me to typo. I should really work on my typing skills as I go along my Xcoding journey.

This chapter was a bit overwhelming with the introduction of classes, objects, and methods. Being new to programming and Objective C/Cocoa is that these concepts are completely foreign to me. I think Ia m getting a grasp of classes and objects, methods is still a little distant. But thankfully the next chapter covers them a little more.

The further I go the more I want to continue on. I think the progression might be a little slower as I deal with more complicated concepts that relate to real world examples (instead of the simple little box I made above).

Actually Opening Up Xcode

0 #

This is a post in my series “Road to Xcode.” I am currently reading Become An Xcoder by Bert Altenburg, Alex Clarke and Philippe Mougin.

05: Compiling and Running a Program

Today I finally broke into launching Xcode and compiling my first example. As you might have guessed the little screenshot above is indeed my example including the debug output (which is all the app really does). This chapter was simply a plunge into using Xcode. I got a little frustrated when I couldn’t find this damn “Run Log window” they referenced when running the example for the first time. So let me help those who might be in the same dilemma. The “Run Log window” is no longer in Xcode 3.x but is now called the “Console” and it doesn’t get launched by default. In the Xcode preferences in the Debugging section I have On Start: Show Console set as well as Auto Clear Debug Console enabled.

Besides mucking about with the debugger and playing with breakpoints and error handling in Xcode, not much coding was really happening. The example does compile and since it is GUIless, the Console is needed to see its output. I didn’t run into any issues running through this chapter besides the stupid “Run Log window.”

Printing with NSLog()

2 #

This is a post in my series “Road to Xcode.” I am currently reading Become An Xcoder by Bert Altenburg, Alex Clarke and Philippe Mougin.

04: Printing on screen

This chapter mainly introduced me to NSLog() and using it to display results even though its main function is to display error messages. The basic idea was mainly for formatting output in a readable way by adding padding to a column of data in integer form or the use of escaping to add special characters like \n for starting a new line.

I have to remind myself that the chapter mainly talked about how to format data being outputted by the NSLog() and not actually dealing with Objective C just yet.

Well, i now theoretically know the process to printing data to the screen and next up is opening up Xcode and compiling the example program the book has been working through so far to introduce me to the basics of declaring a function, defining variables, using operators, and importing header files (I almost sound like I know what I am talking about).

Commenting and Functions

2 #

This is a post in my series “Road to Xcode.” I am currently reading Become An Xcoder by Bert Altenburg, Alex Clarke and Philippe Mougin.

02: No comments? Unacceptable!

There was nothing new going on in this chapter. I was introduced to commenting code. I am actually very familiar with this since I spend some time messing about with CSS/XHTML/PHP. I will sometimes comment over my additions or tweaks to themes and plugins I use in WordPress.

03: Functions

Functions are pretty much where I stopped during my PHP studies. I had a hard time grasping how they were called and how the variables outside the function related to inside the function and returning values. The book hasn’t had me open up Xcode yet, so my playing around with functions and their arguments is non existent at this point. PolyVector has been taking my incessant “why?” very well regarding declaring functions and how the compiler knows where to look etc. I must say I am a little confused on this main() function and why it must be there.

These last chapters were rather short and I am beginning to grow anxious as I near opening up Xcode and my first real encounter with compiling example code. Though these journal entries starting out aren’t full of useful information it is helping me feel not so isolated in my studies.

A Series of Instructions You Say?

3 #

This is a post in my series “Road to Xcode.” I will be embarking on a journey to learn Objective C and Cocoa programming for Mac OS X. This will not be an instructive series but rather a look at what I have learned as well as the resources I am using to gain ground in the wide world of software development. You can follow my progress or check out other posts in this series by heading over to the Road to Xcode tag page.

Introduction

To kick start my Xcoding journey I am reading Become An Xcoder by Bert Altenburg, Alex Clarke and Philippe Mougin. This book is aimed at people with absolutely no coding experience and is free to download in PDF form.

01: A program is a series of instructions

The introduction and first chapter to Become an Xcoder is rather simple. I was introduced to basic programming terminology like data types, integers, operators, etc. Nothing I was too unfamiliar with since I read through basic introductions to PHP which uses the same terminology (I suppose all languages do). Working through the chapter was pretty straight forward except for the introduction to the ++ operator. I don’t know what it is, but I always seem to get hung up on this thing’s function. I understand what it does (a variable will be itself incremented by 1 i.e. x = x + 1). I was having a hard time with the outcome of the variable depending on the order the operator was used, such as x++ versus ++x. The examples written in the book were not extremely helpful, but then again I am only on the first chapter and I am hoping better explanation of the ++ operator will be later on.

As with any introduction I was not compiling any code or even looking at the IDE, but I am eager to continue.