我怎样才能显示在Android平板电脑印地文文平板、印地、电脑、Android

2023-09-12 09:55:25 作者:哥的世界、你不懂

我正在开发的Andr​​oid平板电脑的应用程序。现在,在我的应用我想给印地文文本,所有的的EditText 和按钮的,也是我需要得到从Oracle数据库中的数据,需要存储的 sqlite的。

I am developing an application in Android Tablet. Now in my application i want to show Hindi text for all EditText and Buttons and also i need to get data from Oracle database and need to store in Sqlite.

我知道如何保存和SQLite的,但唯一的检索数据需要显示印地文文本的机器人。

I know how to save and retrieve data from Sqlite but only thing need to show Hindi Text in android.

我已经选中如何显示在Android的印地文文? 但需要清楚地知道我应该怎么需要保存的资产和值的文件夹,即印地文字体。

I already checked How to show Hindi text in android? but need to know clearly what should i have to save in assets and values folder i.e. Hindi font..

有些话是不正确显示。任何一个可以建议我的文件(印地文字体),它正确地显示在印地文的所有单词?

Some words are not displaying properly. Can any one suggest me the file(Hindi font) which shows all words correctly in Hindi?

推荐答案

你很可能希望使用自己的字体自定义应用程序。这篇文章将告诉你如何可以做到这一点。 这是一个简单的例子......在你的项目中称为根目录下创建一个文件夹资产/字体/粘贴的TTF字体文件(在这种情况下Verdana.ttf)。然后,如果你想申请的字体,比如一个TextView,请执行下列操作

your custom apps you will most probably want to use your own font. This post will show you how you can do so. This is a simple example... create a folder in the root of your project called assets/fonts/ then paste the TTF font file (in this case Verdana.ttf). Then, if you want to apply that font to, say a TextView, do the following

TextView im = (TextView ) findViewById(R.id.im);
Typeface face=Typeface.createFromAsset(getAssets(),
                                          "fonts/hindi.ttf");
        im.setTypeface(face);
        im.setText("Hindi font");