FlutterTts class

Constructors

FlutterTts()

Properties

cancelHandler VoidCallback?
getter/setter pair
completionHandler VoidCallback?
getter/setter pair
continueHandler VoidCallback?
getter/setter pair
errorHandler ErrorHandler?
getter/setter pair
getDefaultEngine Future
Future which invokes the platform specific method for getDefaultEngine Returns a String of the default engine name ***Android supported only ***
no setter
getDefaultVoice Future
Future which invokes the platform specific method for getDefaultVoice Returns a Map containing a voice name and locale ***Android supported only ***
no setter
getEngines Future
Future which invokes the platform specific method for getEngines Returns a list of installed TTS engines Android supported only
no setter
getLanguages Future
Future which invokes the platform specific method for getLanguages Android issues with API 21 & 22 Returns a list of available languages
no setter
getMaxSpeechInputLength Future<int?>
Future which invokes the platform specific method for getMaxSpeechInputLength Android supported only
no setter
getSpeechRateValidRange Future<SpeechRateValidRange>
no setter
getVoices Future
Future which invokes the platform specific method for getVoices Returns a List of Maps containing a voice name and locale For iOS specifically, it also includes quality, gender, and identifier Android, iOS, and macOS supported only
no setter
hashCode int
The hash code for this object.
no setterinherited
pauseHandler VoidCallback?
getter/setter pair
progressHandler ProgressHandler?
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
startHandler VoidCallback?
getter/setter pair

Methods

areLanguagesInstalled(List<String> languages) Future
Future which invokes the platform specific method for areLanguagesInstalled Returns a HashMap with true or false for each submitted language. Android supported only
autoStopSharedSession(bool autoStop) Future
Future which invokes the platform specific method for setting the autoStopSharedSession default value is true *** iOS, and macOS supported only***
awaitSpeakCompletion(bool awaitCompletion) Future
Future which sets speak's future to return on completion of the utterance
awaitSynthCompletion(bool awaitCompletion) Future
Future which sets synthesize to file's future to return on completion of the synthesize Android, iOS, and macOS supported only
clearVoice() Future
Future which resets the platform voice to the default
isLanguageAvailable(String language) Future
Future which invokes the platform specific method for isLanguageAvailable Returns true or false
isLanguageInstalled(String language) Future
Future which invokes the platform specific method for isLanguageInstalled Returns true or false Android supported only
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
pause() Future
Future which invokes the platform specific method for pause
platformCallHandler(MethodCall call) Future
Platform listeners
setCancelHandler(VoidCallback callback) → void
setCompletionHandler(VoidCallback callback) → void
setContinueHandler(VoidCallback callback) → void
setEngine(String engine) Future
Future which invokes the platform specific method for setEngine Android supported only
setErrorHandler(ErrorHandler handler) → void
setIosAudioCategory(IosTextToSpeechAudioCategory category, List<IosTextToSpeechAudioCategoryOptions> options, [IosTextToSpeechAudioMode mode = IosTextToSpeechAudioMode.defaultMode]) Future
Future which invokes the platform specific method for setting audio category Ios supported only
setLanguage(String language) Future
Future which invokes the platform specific method for setLanguage
setPauseHandler(VoidCallback callback) → void
setPitch(double pitch) Future
Future which invokes the platform specific method for setPitch 1.0 is default and ranges from .5 to 2.0
setProgressHandler(ProgressHandler callback) → void
setQueueMode(int queueMode) Future
Future which invokes the platform specific method for setQueueMode 0 means QUEUE_FLUSH - Queue mode where all entries in the playback queue (media to be played and text to be synthesized) are dropped and replaced by the new entry. Queues are flushed with respect to a given calling app. Entries in the queue from other calls are not discarded. 1 means QUEUE_ADD - Queue mode where the new entry is added at the end of the playback queue. Android supported only
setSharedInstance(bool sharedSession) Future
Future which invokes the platform specific method for shared instance iOS supported only
setSilence(int timems) Future
Future which invokes the platform specific method for setSilence 0 means start the utterance immediately. If the value is greater than zero a silence period in milliseconds is set according to the parameter Android supported only
setSpeechRate(double rate) Future
Future which invokes the platform specific method for setSpeechRate Allowed values are in the range from 0.0 (slowest) to 1.0 (fastest)
setStartHandler(VoidCallback callback) → void
setVoice(Map<String, String> voice) Future
Future which invokes the platform specific method for setVoice Android, iOS, and macOS supported only
setVolume(double volume) Future
Future which invokes the platform specific method for setVolume Allowed values are in the range from 0.0 (silent) to 1.0 (loudest)
speak(String text) Future
Future which invokes the platform specific method for speaking
stop() Future
Future which invokes the platform specific method for stop
synthesizeToFile(String text, String fileName) Future
Future which invokes the platform specific method for synthesizeToFile Android and iOS supported only
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited