QTextToSpeechEngine

The QTextToSpeechEngine class is the base for text-to-speech engine integrations. More

Inheritance diagram of PySide2.QtTextToSpeech.QTextToSpeechEngine

Synopsis

Virtual functions

Signals

Static functions

Detailed Description

An engine implementation must derive from QTextToSpeechEngine and implement all its pure virtual methods.

class PySide2.QtTextToSpeech.QTextToSpeechEngine([parent=None])
param parent:

PySide2.QtCore.QObject

Constructs the text-to-speech engine base class with parent .

PySide2.QtTextToSpeech.QTextToSpeechEngine.availableLocales()
Return type:

Implementation of availableLocales() .

PySide2.QtTextToSpeech.QTextToSpeechEngine.availableVoices()
Return type:

Implementation of availableVoices() .

static PySide2.QtTextToSpeech.QTextToSpeechEngine.createVoice(name, gender, age, data)
Parameters:
  • name – str

  • genderGender

  • ageAge

  • data – object

Return type:

PySide2.QtTextToSpeech.QVoice

Creates a voice for a text-to-speech engine.

Parameters name , gender , age and data are directly stored in the QVoice instance.

PySide2.QtTextToSpeech.QTextToSpeechEngine.locale()
Return type:

PySide2.QtCore.QLocale

Implementation of locale() .

See also

setLocale()

PySide2.QtTextToSpeech.QTextToSpeechEngine.pause()

Implementation of pause() .

PySide2.QtTextToSpeech.QTextToSpeechEngine.pitch()
Return type:

double

Implementation of pitch() .

See also

setPitch()

PySide2.QtTextToSpeech.QTextToSpeechEngine.rate()
Return type:

double

Implementation of rate() .

See also

setRate()

PySide2.QtTextToSpeech.QTextToSpeechEngine.resume()

Implementation of resume() .

PySide2.QtTextToSpeech.QTextToSpeechEngine.say(text)
Parameters:

text – str

Implementation of say (text ).

PySide2.QtTextToSpeech.QTextToSpeechEngine.setLocale(locale)
Parameters:

localePySide2.QtCore.QLocale

Return type:

bool

Implementation setLocale (locale ).

Return true if the operation was successful. In this case, the current voice (as returned by voice() ) should also be updated to a new, valid value.

See also

locale()

PySide2.QtTextToSpeech.QTextToSpeechEngine.setPitch(pitch)
Parameters:

pitchdouble

Return type:

bool

Implementation of setPitch (pitch ).

Return true if the operation was successful.

See also

pitch()

PySide2.QtTextToSpeech.QTextToSpeechEngine.setRate(rate)
Parameters:

ratedouble

Return type:

bool

Implementation of setRate (rate ).

Return true if the operation was successful.

See also

rate()

PySide2.QtTextToSpeech.QTextToSpeechEngine.setVoice(voice)
Parameters:

voicePySide2.QtTextToSpeech.QVoice

Return type:

bool

Implementation of setVoice (voice ).

Return true if the operation was successful.

See also

voice()

PySide2.QtTextToSpeech.QTextToSpeechEngine.setVolume(volume)
Parameters:

volumedouble

Return type:

bool

Implementation of setVolume (volume ).

Return true if the operation was successful.

See also

volume()

PySide2.QtTextToSpeech.QTextToSpeechEngine.state()
Return type:

State

Implementation of state() .

PySide2.QtTextToSpeech.QTextToSpeechEngine.stateChanged(state)
Parameters:

stateState

PySide2.QtTextToSpeech.QTextToSpeechEngine.stop()

Implementation of stop() .

PySide2.QtTextToSpeech.QTextToSpeechEngine.voice()
Return type:

PySide2.QtTextToSpeech.QVoice

Implementation of voice() .

See also

setVoice()

static PySide2.QtTextToSpeech.QTextToSpeechEngine.voiceData(voice)
Parameters:

voicePySide2.QtTextToSpeech.QVoice

Return type:

object

Returns the engine-specific private data for the given voice .

PySide2.QtTextToSpeech.QTextToSpeechEngine.volume()
Return type:

double

Implementation of volume() .

See also

setVolume()