Merge "Update ImageGenerator to match the latest font names." am: 2fb99930fc am: 4de32b2fb2
Original change: https://android-review.googlesource.com/c/platform/bootable/recovery/+/1607136
MUST ONLY BE SUBMITTED BY AUTOMERGER
Change-Id: I6748c3e0ec2029300e8be95f91aae453b43f0902
diff --git a/tools/image_generator/ImageGenerator.java b/tools/image_generator/ImageGenerator.java
index 1da43e5..d96a861 100644
--- a/tools/image_generator/ImageGenerator.java
+++ b/tools/image_generator/ImageGenerator.java
@@ -113,33 +113,33 @@
private static final Map<String, String> LANGUAGE_TO_FONT_MAP =
new TreeMap<String, String>() {
{
- put("am", "NotoSansEthiopic-Regular");
- put("ar", "NotoNaskhArabicUI-Regular");
+ put("am", "NotoSansEthiopic");
+ put("ar", "NotoNaskhArabicUI");
put("as", "NotoSansBengaliUI-Regular");
put("bn", "NotoSansBengaliUI-Regular");
- put("fa", "NotoNaskhArabicUI-Regular");
- put("gu", "NotoSansGujaratiUI-Regular");
+ put("fa", "NotoNaskhArabicUI");
+ put("gu", "NotoSansGujaratiUI");
put("hi", "NotoSansDevanagariUI-Regular");
put("hy", "NotoSansArmenian-Regular");
- put("iw", "NotoSansHebrew-Regular");
- put("ja", "NotoSansCJK-Regular");
- put("ka", "NotoSansGeorgian-VF");
- put("ko", "NotoSansCJK-Regular");
- put("km", "NotoSansKhmerUI-Regular");
- put("kn", "NotoSansKannadaUI-Regular");
- put("lo", "NotoSansLaoUI-Regular");
+ put("iw", "NotoSansHebrew");
+ put("ja", "NotoSansCJKjp-Regular");
+ put("ka", "NotoSansGeorgian-Regular");
+ put("ko", "NotoSansCJKjp-Regular");
+ put("km", "NotoSansKhmerUI");
+ put("kn", "NotoSansKannadaUI");
+ put("lo", "NotoSansLaoUI");
put("ml", "NotoSansMalayalamUI-Regular");
put("mr", "NotoSansDevanagariUI-Regular");
put("my", "NotoSansMyanmarUI-Regular");
put("ne", "NotoSansDevanagariUI-Regular");
- put("or", "NotoSansOriya-Regular");
- put("pa", "NotoSansGurmukhiUI-Regular");
+ put("or", "NotoSansOriya");
+ put("pa", "NotoSansGurmukhiUI");
put("si", "NotoSansSinhala-Regular");
put("ta", "NotoSansTamilUI-Regular");
- put("te", "NotoSansTeluguUI-Regular");
- put("th", "NotoSansThaiUI-Regular");
- put("ur", "NotoNaskhArabicUI-Regular");
- put("zh", "NotoSansCJK-Regular");
+ put("te", "NotoSansTeluguUI");
+ put("th", "NotoSansThaiUI");
+ put("ur", "NotoNaskhArabicUI");
+ put("zh", "NotoSansCJKjp-Regular");
}
};
@@ -386,7 +386,7 @@
}
String fontName = LANGUAGE_TO_FONT_MAP.getOrDefault(language, DEFAULT_FONT_NAME);
- String[] suffixes = {".otf", ".ttf", ".ttc"};
+ String[] suffixes = {".otf", ".ttf", ".ttc", ".otc"};
for (String suffix : suffixes) {
File fontFile = new File(mFontDirPath, fontName + suffix);
if (fontFile.isFile()) {