NewSpellCheckerSession always returns null

I am trying to connect to the built-in Android spell-checker service on my Note tablet. When i call

final TextServicesManager tsm = (TextServicesManager) getSystemService( Context.TEXT_SERVICES_MANAGER_SERVICE); spellCheck = tsm.newSpellCheckerSession(null, null, this, true); 

spellCheck is always null. Device 4.1.2, so it should at least be able to offer words. Has anyone used this service to give me some pointers? The network is very scarce about this because it usually comes through the keyboard.

+7
source share
2 answers

And I found the answer: Samsung disabled the function on this model. Therefore, I will have to force users to install 2 APKs and jump onto hoops or enable the library as a source in my apk.

+5
source

You might want to set locally explicitly and set the last parameter to false, because it checks the active locales on the device.

 final TextServicesManager tsm = (TextServicesManager) getSystemService( Context.TEXT_SERVICES_MANAGER_SERVICE); spellCheck = tsm.newSpellCheckerSession(null, Local.ENGLISH, this, false); 
+1
source

All Articles