SpeechSynthesisUtterance
The SpeechSynthesisUtterance interface of the Web Speech API represents a speech request. It contains the content the speech service should read and information about how to read it (e.g. language, pitch and volume.)
Documentation SpeechSynthesisUtterance by Mozilla Contributors, licensed under CC-BY-SA 2.5.
Instance Members
text: StringGets and sets the text that will be synthesised when the utterance is spoken.
lang: StringGets and sets the language of the utterance.
voice: SpeechSynthesisVoiceGets and sets the voice that will be used to speak the utterance.
volume: FloatGets and sets the volume that the utterance will be spoken at.
rate: FloatGets and sets the speed at which the utterance will be spoken at.
pitch: FloatGets and sets the pitch at which the utterance will be spoken at.
onstart: haxe.FunctionFired when the utterance has begun to be spoken.
onend: haxe.FunctionFired when the utterance has finished being spoken.
onerror: haxe.FunctionFired when an error occurs that prevents the utterance from being succesfully spoken.
onpause: haxe.FunctionFired when the utterance is paused part way through.
onresume: haxe.FunctionFired when a paused utterance is resumed.
onmark: haxe.FunctionFired when the spoken utterance reaches a named SSML "mark" tag.
onboundary: haxe.FunctionFired when the spoken utterance reaches a word or sentence boundary.
| Name | Type |
|---|---|
text |
String |