title: using android TextToSpeech feature with a pdf file
body: <p>Android provides as with a feature called TextToSpeech with is capable of speaking the text aloud using this code i can make any sentence to be heard aloud in android .</p>
  
  <pre><code>TextToSpeech tts= new TextToSpeech(this, this);
  int result = tts.setLanguage(Locale.US);
  tts.speak(**text**, TextToSpeech.QUEUE_FLUSH, null);
  </code></pre>
  
  <p>Here the <code>text</code> variable stores the sentence to be heard but my problem is that i don't want just a variable there what i want is to place an entire pdf or .doc file over there.So that when i click on play button it starts reading the current pdf or (any extension) file aloud with android <code>TextToSpeech</code> feature . any tutorial with pdf reading capability would help me alot.Thanks</p>