title: Reading Arabic from UTF-8 encoded Text file in android?
body: <p>I am working on an application in which I have a some text in English and Arabic. For the sake of example I can say it as a words meaning application. The word is in English and user will get it's meaning in Arabic. </p>
  
  <p>For Example:</p>
  
  <pre><code>    Test     اختبار    // Test is the word and then there is it's meaning in Arabic
  </code></pre>
  
  <p>But when I read this local file I don't get Arabic as intended. Instead I get some strange characters. I am making sure that file is UTF-8 encoded and when I read the file I again pass encoding scheme to be UTF-8..but it does not wwork. Code snippet is as follows:</p>
  
  <pre><code>    InputStream inputStream = resources.openRawResource(R.raw.textfile);
      BufferedReader reader = new BufferedReader(new InputStreamReader(inputStream, "utf-8"));
  
      try {
          String line;
          while((line = reader.readLine()) != null) {
              String[] strings = TextUtils.split(line, " ");
              if (strings.length &lt; 2) continue;
              addWord(strings[0].trim(), strings[1].trim());
          }
      } finally {
          reader.close();
      }
  </code></pre>
  
  <p>Any help is appreciated..Thanks..!!!</p>