Arabic language in android [closed]
Asked Answered
S

4

2

android still not fully support Arabic language even in last version 2.3 and maybe not in 3.0 also

any way i am programmer if i want to make it Arabic support how to start to make it fully support Arabic ?

because i found some the companies like Samsung and HTC add fully Arabic support to there devices this mean every body if he has a good knowledge with the system can add support.

Shalne answered 21/12, 2010 at 10:29 Comment(1)
Follow this helpful link and enjoy! There is a complete description of problem and an algorithm as its solution.Orelu
K
1

Android 3.0 Honeycomb has official native support for Arabic.

source: xda-developers, http://bit.ly/honeycomb-arabic , ArDroid

As for smart phones, CyanogenMod 7 has decent Arabic support.

Kashmir answered 28/1, 2011 at 23:2 Comment(0)
J
1

If you want arabic on your Android device you can use CyanogenMod 7 based on Android gingerbread(2.3) they use arabic shaper in their rom soyou can read arabic everywhere and in the latest version of cyanogen they added an arabic keyboard.

Companies like HTC and samsaung... made special arabic room for devices exported to MEA , but It does not supported well, arabic OTA updates doesn't come 90%.

Joktan answered 2/9, 2011 at 5:37 Comment(0)
B
0

I found a couple projects which attempt that, maybe you could look at those and see what exactly needs to be done

https://sites.google.com/a/ut.utm.edu/arabic-android/

Broadway answered 21/12, 2010 at 10:42 Comment(0)
H
0

You can use Alefonizer .. its a lib renders arabic characters in android devices that dont support Arabic

here is a smaple

package org.alefon.com;


import www.alefon.com.alefonizerArarbic.AlfnFixText;
import www.alefon.com.alefonizerArarbic.AlfnLining;
import android.app.Activity;
import android.os.Bundle;
import android.view.ViewTreeObserver;
import android.view.ViewTreeObserver.OnGlobalLayoutListener;
import android.widget.TextView;



public class MainActivity extends Activity {
    private TextView tv;
private AlfnFixText alfntx;

    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);  
        alfntx = new AlfnFixText(true); 
        tv = (TextView) findViewById(R.id.tx); 
        String text = "قال ابن رشد:الله ليمكن ٔان يعطينا عقول ويعطينا شرأيع مخالفة لها";   

        tv.setText(text); 

        ViewTreeObserver vto = tv.getViewTreeObserver(); 
        vto.addOnGlobalLayoutListener(new OnGlobalLayoutListener() { 
            @Override
            public void onGlobalLayout() {

                AlfnLining alflining = new AlfnLining();
                String rlines = alflining.getTextLines(tv.getWidth(),
                        tv.getPaint(), tv.getText().toString(), true);
                if (rlines != null) {
                    String lli[] = rlines.split("\n");
                    String fn = "";
                    for (String st : lli) {

                        try {
                            st = alfntx.getFixedText(st);
                        } catch (Exception e) {

                            e.printStackTrace();
                        }
                        fn += st + "\n";
                    }
                    tv.setText(fn);
                }
                ViewTreeObserver obs = tv.getViewTreeObserver();
                obs.removeGlobalOnLayoutListener(this);
            }
        });
    }

}

Just remember that you would need to use a font that contains Arabic character & OTL for Arabic ..i.e. Arial ..

====== update =======

Android studio use UTF-8 as file encoding.. but you can change it see screenshot:

enter image description here

Good luck,

Hectogram answered 31/5, 2013 at 10:4 Comment(2)
Which UTF have to use for android studio to support arabic in android studio ?Game
Anand Savjani, please see my updated answerHectogram

© 2022 - 2024 — McMap. All rights reserved.