Writing your own software for OSX
When i get my iMac, i'd like to get back into programming. I started in windows but it got obnoxious and GUI stuff was a mess and disugsting. To make it look great costed memory and performance, etc...
Anyhow, i don't know much about 'power-using' a mac yet but i assume all the tools we need are available?
Is there software i ahve to buy to program, ie: Visual Basic or C++ suites?
Does anyone have any suggestions where to start? Books, etc..? I'd like to wait a little bit for Tiger release so i can go head-first into 64-bit stuff.
Or should i just start now and overlap the new stuff?
Any suggestions welcome. thnx.
Anyhow, i don't know much about 'power-using' a mac yet but i assume all the tools we need are available?
Is there software i ahve to buy to program, ie: Visual Basic or C++ suites?
Does anyone have any suggestions where to start? Books, etc..? I'd like to wait a little bit for Tiger release so i can go head-first into 64-bit stuff.
Or should i just start now and overlap the new stuff?
Any suggestions welcome. thnx.
Comments
All the standard Unix tools are there, as well.
as for books, oreilly usually has pretty good ones so you might want to check them out. books by hillegass are quite popular among mac programmers too.
is it a pretty hard language to learn?
:c
Originally posted by cubedcompanies
thanks, i installed the xcode but it looked intimidating; i haven't stepped too deep yet, busy studying for college test on wed.
is it a pretty hard language to learn?
:c
If you're comfortable with both C and object-oriented development, Objective-C itself is pretty simple. It adds very little syntax to C, but the little bit it adds is incredibly powerful in actual use.
Cocoa, like any API its size, has a pretty steep learning curve. You have to spend a certain amount of time getting used to the way it approaches things, and the naming conventions, and so forth — the same as you would for any large API. Personally, I find Cocoa much easier to handle than Java's elephantine and occasionally convoluted libraries (not to even mention the psychological scars I got learning VMS' C API). Once you "get" Cocoa, it's pretty easy to use.
There are lots of good books on OS X programming. In no particular order:
- Cocoa Programming on Mac OS X
- Cocoa Programming
- Cocoa Recipes for Mac OS X
- Building Cocoa Applications: A Step by Step Guide
- Learning Cocoa with Objective-C
None of these are of the LEARN COCOA IN 30 DAYS OMG!!! class of tutorial. They're all solid tomes from veteran developers. The last volume is written by an Apple employee.If you poke around a bit in the online help, you'll find tutorials for building applications. Look in the help for NSDocument, for example.
Good luck! Speaking for myself, Cocoa programming is fun.
What kind of programming can you do already (languages, problem fields, ...) ?
What kind of programming do you want to learn, or what kind of software you want to write?
Do you have specific tool skills, preferences or requirements (IDE, editor, software engineering tools, ...)?
It would be a lot easier to help you if you answered these questions first.
Then there's Interface Builder. If it weren't for IB, I'd still be developing in Java. I just love being able to build my GUI through drag -n- drop. It's kinda like VB if you've played with that at all, except more powerful. You can wire up GUI actions like wiring a button to display a window with no code whatsoever.
Interface Builder took me some time to get used to, just because the steps for subclassing / instantiating objects, creating actions / outlets, generating files, and writing files back to the XCode project aren't always intuitive. Still after doing this for a couple of days straight (thanks to Eric Tremblay's Cocoa programming class www.macdev.ca ) it's almost become 2nd nature.
Not to say I make great looking GUIs, one look at my program will show you that
I'd say to do the sample currency converter app in the Cocoa Tutorial to start with. Then grab Aaron Hillegass' book or any of the other books mentioned in this thread (heck, even Cocoa for Dummies is a good book) and work through that. As you do, write down your ideas for programs and try to build those as well.
Originally posted by PBG4 Dude
Then there's Interface Builder. If it weren't for IB, I'd still be developing in Java. I just love being able to build my GUI through drag -n- drop. It's kinda like VB if you've played with that at all, except more powerful. You can wire up GUI actions like wiring a button to display a window with no code whatsoever.
Just interested - did you ever try Java interface builders like the one in Borland JBuilder? I had to do some work in JBuilder once and I remember it had an interface builder. This was about four, five years ago.
Originally posted by Gon
Just interested - did you ever try Java interface builders like the one in Borland JBuilder? I had to do some work in JBuilder once and I remember it had an interface builder. This was about four, five years ago.
No, I hand-coded all my Java Swing UIs. In my GUI apps I probably write more GUI code when compared to actual "do something" code.
I'm sure it's not as elegant or efficient as Cocoa, but I knew BASIC and for what I needed it worked. (I'm a psychologist and create software to run experiments - the software is pretty simple and doesn't have really any user options.)
Well I've used: QBASIC (lol) > Pascal > VBasic (my favorite thus far) > C++ (light) > JAVA (college course) > PHP (light) > ASP (lighter) > and i think that's about it. Some other nonsense here and there but those are the core.
I don't really have an objective to programming rather just to learn something more about another type of computer. I've done everything i wanted to on a PC.
If I should get good, perhaps some small programs for the advertising industry, similar to iWork or what not.
iLife-lite apps basically. Nothign too complex but acheives usefulness in my life.
:c
You can code in the pure, command line environment in:
C
C++
Objective-C
Objective-C++
Java (including Swing and AWT)
AppleScript
Or you can go for the Carbon environment (C++)
or the Cocoa environment (Obj-C, Java, Obj-C++)
Or there are bridges for Python, Ruby, AppleScript, and Perl for a semi-Cocoa environment.
There are even setups that allow for Swing programming through the nice Apple tools, and maybe even QT (not QuickTime).
There are even efforts to get Mono (an open source implementation of C# plus a sampling of the .Net frameworks) to be a first class platform on MacOS X.
Basically you have an awful lot of choice all for free with MacOS X. The vast array of choices can be a bit daunting.
:c
All I can say is is that I dig working with Obj-C & Interface Builder to build new programs. Each language has its own strengths so what language you learn depends on what you want to do. For general purpose OS X my pick is Obj-C. I'm not raking in the dough from my acclaimed award winning software so take my recommendations with a grain of salt.
What they are really pushing is the Cocoa frameworks, and the accessors in Java and Obj-C are as identical as they can be given the differences in the languages.
If you already know Java, continue to use Java (unless you are creating First Person Shooters, then you need direct access to pointers, and most of your code is going to be in C with C++ or Obj-C wrappers around it). The big thing is to learn Cocoa-Java... Cocoa is a big umbrella with a lot of classes, methods, interfaces, and best practices to get used to. Learn it in a language you are familiar with, and then if you decide to move to Obj-C (or just learn it on the side) then you will have Cocoa under your belt and can concentrate on what makes Obj-C Obj-C.
Originally posted by cubedcompanies
well if Apple wants Cocoa, it must be for good reason. I think i'll hold out and buy a book when Tiger strikes.
If I were you I'd get a book now and get up to speed so that when Tiger hits, you won't need more than the new developer docs to catch up on the new features.
Cocoa hasn't changed that much, you know. It's been around for a long time, and although Apple has been adding things and fleshing them out, the basic set of classes goes back to the 1980s.
gawd i wish i could get rid of this PC a bit quicker.
Originally posted by cubedcompanies
in your opinion, what is the strongest most versital language to learn? if you have time, why i'd want to use one language over the other aside from JAVA.
What do you want to do? If you are mostly trying to create reports, or otherwise munging text files, the learn perl. Mostly doing statistical or other numeric/scientific work: learn fortan (otherwise stay away at all costs). Doing real-time or time sensitive work (first person shooters): C is your friend, C++ is your cousin. Working on large enterprise apps that have to have a hundred different interfaces: Java is the way to go. Trying to create a workflow to tie a number of different programs tother: take you pick from AppleScript, shell scripts, VisualBasic, or Tcl. Working on small web applications: PHP (or possible Biferno). Working on web portals to established Windows based proprietary applications (wit lots of DLL's) use ASP or ASP.NET. Working for the US AirForce: ADA all the way... (*sigh*). etc...
The short of it is that there is no single language that works best in all problem spaces. Once you get going you should try an learn a whole lot of languages each one will teach you something else about programming (even if it is just that you never want to see another line of Lisp again in your life).