0

I will add Laotian and Khmer language support in android 4.1(jelly bean). The process steps are as follows:

1.Modify languages_full.mk file lo_LA km_MM.

PRODUCT_LOCALES := en_US en_GB es_ES es_US fr_FR zh_CN zh_TW hi_IN it_IT pt_PT ru_RU lo_LA km_MM

2.Add Laotian, Khmer font file.

Font file is copied to the:/frameworks/base/data/fonts/
Laotian font file:Alice_3_Medium.ttf
Khmer font file:Klbachmool_Regular.ttf

3. Modify jb/frameworks/base/data/fonts/Android.mk

 font_src_files := \
Roboto-Regular.ttf \
Roboto-Bold.ttf \
Roboto-Italic.ttf \
Roboto-BoldItalic.ttf \
DroidSerif-Regular.ttf \
DroidSerif-Bold.ttf \
DroidSerif-Italic.ttf \
DroidSerif-BoldItalic.ttf \
DroidSansMono.ttf \
Clockopia.ttf \
AndroidClock.ttf \
AndroidClock_Highlight.ttf \
AndroidClock_Solid.ttf \
Alice_3_Medium.ttf \
Klbachmool_Regular.ttf

4. jb /frameworks/base/data/fonts/fonts.mk

4.1
PRODUCT_PACKAGES := \
DroidSansFallback.ttf \
Roboto-Regular.ttf \
Roboto-Bold.ttf \
Roboto-Italic.ttf \
Roboto-BoldItalic.ttf \
Roboto-Light.ttf \
Roboto-LightItalic.ttf \
RobotoCondensed-Regular.ttf \
RobotoCondensed-Bold.ttf \
RobotoCondensed-Italic.ttf \
RobotoCondensed-BoldItalic.ttf \
DroidNaskh-Regular.ttf \
DroidNaskh-Regular-SystemUI.ttf \
DroidSansDevanagari-Regular.ttf \
DroidSansHebrew-Regular.ttf \
DroidSansHebrew-Bold.ttf \
DroidSansThai.ttf \
DroidSerif-Regular.ttf \
DroidSerif-Bold.ttf \
DroidSerif-Italic.ttf \
DroidSerif-BoldItalic.ttf \
DroidSansMono.ttf \
DroidSansArmenian.ttf \
DroidSansGeorgian.ttf \
AndroidEmoji.ttf \
Clockopia.ttf \
AndroidClock.ttf \
AndroidClock_Highlight.ttf \
AndroidClock_Solid.ttf \
Alice_3_Medium.ttf \
Klbachmool_Regular.ttf
4.2
PRODUCT_COPY_FILES :=frameworks/base/data/fonts/system_fonts.xml:$(TARGET_COPY_OUT_SYSTEM)/etc/system_fonts.xml \    frameworks/base/data/fonts/fallback_fonts.xml:$(TARGET_COPY_OUT_SYSTEM)/etc/fallback_fonts.xml \
frameworks/base/data/fonts/fallback_fonts-km.xml:$(TARGET_COPY_OUT_SYSTEM)/etc/fallback_fonts-km.xml \
frameworks/base/data/fonts/fallback_fonts-lo.xml:$(TARGET_COPY_OUT_SYSTEM)/etc/fallback_fonts-lo.xml

5. add file: jb/frameworks/base/data/fonts/fallback_fonts-km.xml jb/frameworks/base/data/fonts/fallback_fonts-lo.xml

add frameworks\base\core\res\res\values-lo-rLA frameworks\base\core\res\res\values-km-rMM

last: system overall compile

run result:in Setting switch Laos and Khmer.Laos encoded unicode text can not be drawn on UI, Khmer encoded unicode text can not be drawn on UI. What is the reason?

4

1 回答 1

0

人们说高棉 Unicode 渲染已经在 J​​elly Bean (4.1) 中正常工作,缺少的只是字体。

这里有一些可能对您有所帮助的链接:

  1. 在大多数三星设备中使用 Jelly Bean 将字体复制到 FlipFont 的方法:http ://www.khmertype.org/2012/10/khmerapk-on-galaxy-note-ii-updated.html
  2. 修改字体系统的方法:http: //nokorsoft.com/2012/07/android-jelly-bean-os-supports-khmer-unicode/

希望它有所帮助,它可能为您提供另一种解决高棉 Unicode 问题的方法。

于 2012-11-01T16:11:14.060 回答