Mercurial > cpython-lru_cache-weakref
annotate Doc/mac/libmacspeech.tex @ 21467:4e35fa5d5708 legacy-trunk
Add documentation for the help() built-in; contributed by Ka-Ping Yee.
This is part of SF patch #494622.
| author | Fred Drake <fdrake@acm.org> |
|---|---|
| date | Tue, 18 Dec 2001 16:31:08 +0000 |
| parents | 70bdf84862ad |
| children |
| rev | line source |
|---|---|
| 8915 | 1 \section{\module{macspeech} --- |
| 10334 | 2 Interface to the Macintosh Speech Manager} |
| 3 | |
|
8715
c750c7a21e03
Adjusted to use the new \declaremodule \modulesynopsis \localmoduletable
Fred Drake <fdrake@acm.org>
parents:
7866
diff
changeset
|
4 \declaremodule{builtin}{macspeech} |
| 10334 | 5 \platform{Mac} |
|
8715
c750c7a21e03
Adjusted to use the new \declaremodule \modulesynopsis \localmoduletable
Fred Drake <fdrake@acm.org>
parents:
7866
diff
changeset
|
6 \modulesynopsis{Interface to the Macintosh Speech Manager.} |
|
c750c7a21e03
Adjusted to use the new \declaremodule \modulesynopsis \localmoduletable
Fred Drake <fdrake@acm.org>
parents:
7866
diff
changeset
|
7 |
| 2452 | 8 |
| 9 This module provides an interface to the Macintosh Speech Manager, | |
| 7866 | 10 \index{Macintosh Speech Manager} |
| 11 \index{Speech Manager, Macintosh} | |
|
2527
815dfaa6a778
small changes by Soren Larsen
Guido van Rossum <guido@python.org>
parents:
2453
diff
changeset
|
12 allowing you to let the Macintosh utter phrases. You need a version of |
| 7866 | 13 the Speech Manager extension (version 1 and 2 have been tested) in |
| 14 your \file{Extensions} folder for this to work. The module does not | |
|
19875
70bdf84862ad
Added a note that these are not available under Carbon (or
Jack Jansen <jack.jansen@cwi.nl>
parents:
10334
diff
changeset
|
15 provide full access to all features of the Speech Manager. |
|
70bdf84862ad
Added a note that these are not available under Carbon (or
Jack Jansen <jack.jansen@cwi.nl>
parents:
10334
diff
changeset
|
16 |
|
70bdf84862ad
Added a note that these are not available under Carbon (or
Jack Jansen <jack.jansen@cwi.nl>
parents:
10334
diff
changeset
|
17 This module is only available on MacOS9 and earlier in classic PPC |
|
70bdf84862ad
Added a note that these are not available under Carbon (or
Jack Jansen <jack.jansen@cwi.nl>
parents:
10334
diff
changeset
|
18 MacPython. |
| 2452 | 19 |
| 20 \begin{funcdesc}{Available}{} | |
| 21 Test availability of the Speech Manager extension (and, on the | |
| 7866 | 22 PowerPC, the Speech Manager shared library). Return \code{0} or |
| 23 \code{1}. | |
| 2452 | 24 \end{funcdesc} |
| 25 | |
| 26 \begin{funcdesc}{Version}{} | |
|
2527
815dfaa6a778
small changes by Soren Larsen
Guido van Rossum <guido@python.org>
parents:
2453
diff
changeset
|
27 Return the (integer) version number of the Speech Manager. |
| 2452 | 28 \end{funcdesc} |
| 29 | |
| 30 \begin{funcdesc}{SpeakString}{str} | |
| 31 Utter the string \var{str} using the default voice, | |
| 32 asynchronously. This aborts any speech that may still be active from | |
| 7866 | 33 prior \function{SpeakString()} invocations. |
| 2452 | 34 \end{funcdesc} |
| 35 | |
| 36 \begin{funcdesc}{Busy}{} | |
| 37 Return the number of speech channels busy, system-wide. | |
| 38 \end{funcdesc} | |
| 39 | |
| 40 \begin{funcdesc}{CountVoices}{} | |
| 41 Return the number of different voices available. | |
| 42 \end{funcdesc} | |
| 43 | |
| 44 \begin{funcdesc}{GetIndVoice}{num} | |
| 7866 | 45 Return a \pytype{Voice} object for voice number \var{num}. |
| 2452 | 46 \end{funcdesc} |
| 47 | |
| 7866 | 48 \subsection{Voice Objects} |
| 49 \label{voice-objects} | |
| 50 | |
| 2452 | 51 Voice objects contain the description of a voice. It is currently not |
| 52 yet possible to access the parameters of a voice. | |
| 53 | |
|
7277
bf4e790bd61a
Remove all \bcode / \ecode cruft; this is no longer needed. See previous
Fred Drake <fdrake@acm.org>
parents:
6647
diff
changeset
|
54 \setindexsubitem{(voice object method)} |
| 2452 | 55 |
| 7866 | 56 \begin{methoddesc}[Voice]{GetGender}{} |
| 57 Return the gender of the voice: \code{0} for male, \code{1} for female | |
| 58 and \code{-1} for neuter. | |
| 59 \end{methoddesc} | |
| 2452 | 60 |
| 7866 | 61 \begin{methoddesc}[Voice]{NewChannel}{} |
| 62 Return a new Speech Channel object using this voice. | |
| 63 \end{methoddesc} | |
| 2452 | 64 |
| 7866 | 65 \subsection{Speech Channel Objects} |
| 66 \label{speech-channel-objects} | |
| 67 | |
| 68 A Speech Channel object allows you to speak strings with slightly more | |
| 69 control than \function{SpeakString()}, and allows you to use multiple | |
| 2452 | 70 speakers at the same time. Please note that channel pitch and rate are |
|
2527
815dfaa6a778
small changes by Soren Larsen
Guido van Rossum <guido@python.org>
parents:
2453
diff
changeset
|
71 interrelated in some way, so that to make your Macintosh sing you will |
| 2452 | 72 have to adjust both. |
| 73 | |
| 7866 | 74 \begin{methoddesc}[Speech Channel]{SpeakText}{str} |
| 2452 | 75 Start uttering the given string. |
| 7866 | 76 \end{methoddesc} |
| 2452 | 77 |
| 7866 | 78 \begin{methoddesc}[Speech Channel]{Stop}{} |
| 2452 | 79 Stop babbling. |
| 7866 | 80 \end{methoddesc} |
| 2452 | 81 |
| 7866 | 82 \begin{methoddesc}[Speech Channel]{GetPitch}{} |
|
2527
815dfaa6a778
small changes by Soren Larsen
Guido van Rossum <guido@python.org>
parents:
2453
diff
changeset
|
83 Return the current pitch of the channel, as a floating-point number. |
| 7866 | 84 \end{methoddesc} |
| 2452 | 85 |
| 7866 | 86 \begin{methoddesc}[Speech Channel]{SetPitch}{pitch} |
| 2452 | 87 Set the pitch of the channel. |
| 7866 | 88 \end{methoddesc} |
| 2452 | 89 |
| 7866 | 90 \begin{methoddesc}[Speech Channel]{GetRate}{} |
| 2452 | 91 Get the speech rate (utterances per minute) of the channel as a |
| 92 floating point number. | |
| 7866 | 93 \end{methoddesc} |
| 2452 | 94 |
| 7866 | 95 \begin{methoddesc}[Speech Channel]{SetRate}{rate} |
| 2452 | 96 Set the speech rate of the channel. |
| 7866 | 97 \end{methoddesc} |
| 2452 | 98 |
