Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TTS openInstallTts Plugin CDVTTS does not respond to method call openInstallTts (iOS) #8

Open
Simbaclaws opened this issue Apr 2, 2021 · 2 comments

Comments

@Simbaclaws
Copy link

Simbaclaws commented Apr 2, 2021

Hi there,

I made a button called: Install voices, which when clicked on android goes to the correct page to select a voice.
However, this button gives the following errors when clicked on iOS:

To Native Cordova ->  TTS openInstallTts TTS1400231065 ["options": []]
Error: Plugin CDVTTS does not respond to method call openInstallTts:.
Ensure plugin method exists and uses @objc in its declaration

I need this working on iOS since the only voice a user can at this point select is the default Xander voice (dutch). This means that the user needs to have the option to install other dutch voices in their phone.

Looking at the native Objective C code, this method does not seem to exist yet for iOS.
I'm going to try and find out how I can open this specific settings page in iOS native and see if I can help make this functionality for the plugin since I need it for our next version of our app.

I have little to no experience in Objective C so I made a stackoverflow post here:
https://stackoverflow.com/questions/66919691/how-can-i-open-the-install-voices-settings-page-in-objective-c-ios

@spasma
Copy link
Owner

spasma commented Apr 2, 2021

You can specify a voice by providing identifier in the speak-command. use getVoices to get a list with compatible voices. My device has a list with over 50 voices on iOS. openInstallTTS is not available on iOS as they don't provide an option to add/install voices.

@Simbaclaws
Copy link
Author

Simbaclaws commented Apr 3, 2021

Actually, in some languages such as dutch only the standard xander voice is available because the plugin doesn't pick up siri male and siri female for that language. You could obviously choose one of the other language voices but this would sound aweful as they're not made for that language.

openInstallTTS is not available on iOS as they don't provide an option to add/install voices.

Have you ever looked under:
Settings -> accesibility -> spoken content -> voices -> your language?

I'm pretty sure there is a cloud icon with a downward pointing arrow that you can click next to some voice in order to download them from apple. (The page I show in the screenshot of the stackoverflow post)

In fact, these downloaded voices will show up in the getvoices command.

And since the dutch language doesn't pick up any of the siri's I'm forced to show the user a way to download the other voices to be able to make a choice. Otherwise only xander will show up.

The stackoverflow post I made shows that opening these specific voice install pages within settings is not possible in a official way and is only possible by using private apple APIs that apple will suspend your account for and delete your apps for if being used in your app. See: https://gist.github.com/phynet/471089a51b8f940f0fb4 for proof. This isn't even being mentioned in the apple documentation for the corresponding openURL() and open() objective-c functions, so you just have to send in your app in order to find out that this is not supported by apple...

I'm going to create a enhancement request towards apple for the feature of having a public api to jump to pages within the settings app, as this is something that doesn't yet exist. And is being wanted by a lot of iOS developers.

The only other solution I can currently think of is creating a dialog with instructions that point to the voices install page in system settings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants