Progress updates are only supported for native speech synsthesis. Use the default engine to ensure support for progress updates. Chromium#41195426
Android
Change the minimum Android sdk version to 21 (or higher) in your android/app/build.gradle file.
minSdkVersion 21
Update the Kotlin Gradle Plugin Version
Change the verision of the Kotlin Gradle plugin to 1.9.10.
If your project was created with a version of Flutter before 3.19, go to the android/build.gradle file and update the ext.kotlin_version:
ext.kotlin_version = '1.9.10'
Otherwise go to android/settings.gradle and update the verion of the plugin org.jetbrains.kotlin.android:
id "org.jetbrains.kotlin.android" version "1.9.10" apply false
Android TTS does not support the pause function natively, so we have implemented a work around. We utilize the native onRangeStart() method to determine the index of start when pause is invoked. We use that index to create a new text the next time speak is invoked. Due to using onRangeStart(), pause works on SDK versions >= 26. Also, if using start and end offsets inside of setProgressHandler(), you'll need to keep a track of them if using pause since they will update once the new text is created when speak is called after being paused.
await flutterTts.pause()
iOS
There's a known issue with integrating plugins that use Swift into a Flutter project created with the Objective-C template. Flutter#16049
To set audio category and options with optional mode (iOS only). The following setup allows background music and in-app audio session to continue simultaneously: