November 2016
Intermediate to advanced
480 pages
14h 42m
English
Right now, users of VocalTextEdit can click the Speak or Stop buttons at any time. That is not ideal: Clicking Speak while VocalTextEdit is currently synthesizing will abruptly restart the vocalization, for example. Modify VocalTextEdit so that users can only click on Speak if the application is not currently synthesizing and only click Stop when it is.
To complete this challenge, you will need a way to set the enabled property of the two buttons. You will also need a way to know when speaking ends. (You already know when it starts.) Investigate the documentation for the NSSpeechSynthesizerDelegate protocol to find out how to do these things.
Read now
Unlock full access