Chapter 1. Introducing MacRuby

 

This chapter covers

  • Exploring and installing MacRuby
  • Important Cocoa concepts
  • Objective-C and Ruby fundamentals
  • MacRuby syntax and methods
  • Developing with the Xcode IDE

MacRuby gives you the ability to write full-fledged Mac applications while enjoying the benefits of the Ruby language. You won’t take a deep dive into writing your first releasable application worthy of the Mac App Store just yet—you’ll do that in chapter 2. To write great MacRuby applications, you first need to become familiar with its foundation. The MacRuby language is deeply rooted in the Ruby and Objective-C languages so it’s important to have a good understanding of both of these to fully leverage all that MacRuby offers.

In this chapter, we’ll briefly cover the Cocoa framework, Ruby, and Objective-C. After you have an understanding of these topics, we’ll dive into some real MacRuby code. You’ll even get a chance to write a Hello World application; we’ll show you two approaches to user interface development.

To get started, let’s learn what MacRuby is all about and get it installed on your system.

1.1. Introducing MacRuby

1.2. Cocoa: What you need to know

1.3. Objective-C and Ruby: what you need to know

1.4. Diving into MacRuby

1.5. Hello World, part 2

1.6. Summary