How to add my own settings to system settings?

I saw applications that managed to add their own flags to the system settings without requiring root access .

For example, when a new TTS engine is installed, it adds its own elements to the screen Voice input & output > Text-to-speech settings :

enter image description here

How do they do it?

If I want to add my own parameter to this Text-to-speech settings screen, what search, API and / or documentation should I look for?

+2
source share
1 answer

How do they do it?

After examining the TtsEngine sample application in the SDK, it will look like this:

Step # 1: Deploy TTS. Developers who try to use this object to capture arbitrary other material in "Settings" will be taken into view.

Step # 2: In the manifest entry for this service, use the <meta-data> element with the android:name="android.speech.tts" and android:resource attribute pointing to the XML resource.

Step # 3: Create the aforementioned XML resource similar to the following:

 <tts-engine xmlns:android="http://schemas.android.com/apk/res/android" android:settingsActivity="your.settings.activity.GoesHere" /> 

Alas, this seems to be undocumented. Leastways, I do not find any links to this material when I search the online developer guide.

+2
source

Source: https://habr.com/ru/post/954397/


All Articles