6 Delegation

In this chapter, you will begin a new application named SpeakLine. This application will use the NSSpeechSynthesizer class to enable users to type in a line of text and hear it spoken by the OS X speech synthesizer.

Figure 6.1  SpeakLine in action

SpeakLine in action

Let’s take a moment to talk about the two buttons and how they will function in the app. The buttons that start and stop the speech synthesizer will be disabled when appropriate: the Speak button will be disabled when the speech synthesizer is speaking; the Stop button will be disabled when the speech synthesizer is not speaking. A disabled button is grayed-out

Get Cocoa Programming for OS X: The Big Nerd Ranch Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.