Code example for TextToSpeech

Methods: isLanguageAvailablesetLanguagesetOnUtteranceProgressListener

0
	} 
 
	@Override 
	public void onInit(int status) {
		// TODO Auto-generated method stub 
		this.tts.setOnUtteranceProgressListener(this);
		if(TextToSpeech.SUCCESS == status){
			Locale locale = Locale.JAPAN;
			if(this.tts.isLanguageAvailable(locale) >= TextToSpeech.LANG_AVAILABLE){
				this.tts.setLanguage(locale);
				Log.d("test","language set");
			}else{ 
				 
				Log.d("", "Error setlocal");
			} 
		}else{ 
			Log.d("","error init");
		} 
	} 
	 
Stop searching for code, let great code find you!  Add Codota to your java IDE