secondlife / jira-archive

2 stars 0 forks source link

[BUG-10457] Asian font can't be seen on Windows 10 or Mac OS X El Capitan #784

Closed sl-service-account closed 8 months ago

sl-service-account commented 9 years ago

Steps to Reproduce

Typing or pasting some Asian characters in input field or notecard.

Actual Behavior

CJK, Indian or Thai characters are displayed as boxes (tofu)

Expected Behavior

These language are displayed as it be

Other information

This post is same to BUG-9759, BUG-10382 and BUG-10444. But I posted this because I have an essential resolution for this trouble forever on all platform viewer supported.

Editing fonts.xml like described in BUG-10382 is not an essential resolution for this problem. Do you like to worry about OS vendor may change system font name every time upgrading OS? Or do you like to upgrade SL viewer(or patch fonts.xml) every time they change system fonts? No, no, not at all!

BTW I've concerned that viewer wouldn't show Hindi or Thai language, although Hindi is 4th language having native speakers on the earth. ( https://en.wikipedia.org/wiki/List_of_languages_by_number_of_native_speakers )

SL Viewer has an open source font collection named DejaVu included in resource folder which has version 2.3 covering 150 languages but it lacks many Asian languages like CJK or Indian languages. DejaVu doesn't have Thai font although description includes Thai. Now DejaVu is version 2.35, a few languages had added. It's time to replace DejaVu fonts. (http://dejavu-fonts.org/wiki/Download )

There are some open source Asian fonts now, SL viewer should bundle these fonts. I listed up fonts to be inculded, chose them to cover top 25 languages. They are released under SIL Open Font License or Apache License.

NotoSansBengali-Regular.ttf NotoSansDevanagari-Regular.ttf NotoSansGurmukhi-Regular.ttf NotoSansTamil-Regular.ttf NotoSansTelugu-Regular.ttf NotoSansThai-Regular.ttf DroidSansFallback.ttf

I made a patch including these fonts with updated fonts.xml. New fonts.xml includes font settings for these fonts, and replaced fallback font settings only have Arial Unicode. Arial Unicode is included in MS Office or Mac OS X, covers 172 languages but not open source so we can't bundle it in our viewer (and so large, 23Mbytes).

NotoSans fonts are from https://github.com/googlei18n/noto-fonts/tree/master/hinted DroidSansFallback is from repository for Android OS: https://android.googlesource.com/platform/frameworks/base/

There are Noto CJK fonts but so large file size, about 16Mbytes each Chinese, Japanese and Korean but DroidSansFallback.ttf is only 3.5Mbytes including CJK in one file.

After this modification, we can see 169 languages in 184 defined in ISO 639-1. If you have Arial Unicode in your system folder, it increases to 175 languages. Viewer size will grow a bit(about 4Mbytes), but it is worth to do it.

Please apply this patch as soon as possible, Oz. After that, you never get this kind of trouble. (except CEF viewer:P)

Attachments

Original Jira Fields | Field | Value | | ------------- | ------------- | | Issue | BUG-10457 | | Summary | Asian font can't be seen on Windows 10 or Mac OS X El Capitan | | Type | Bug | | Priority | Unset | | Status | Closed | | Resolution | Duplicate | | Reporter | Pell Smit (pell.smit) | | Created at | 2015-10-12T01:45:50Z | | Updated at | 2017-05-08T23:44:12Z | ``` { 'Business Unit': ['Platform'], 'Date of First Response': '2015-10-12T13:00:44.819-0500', "Is there anything you'd like to add?": "This post is same to BUG-9759, BUG-10382 and BUG-10444.\r\nBut I posted this because I have an essential resolution for this trouble forever on all platform viewer supported.\r\n\r\nEditing fonts.xml like described in BUG-10382 is not an essential resolution for this problem.\r\nDo you like to worry about OS vendor may change system font name every time upgrading OS?\r\nOr do you like to upgrade SL viewer(or patch fonts.xml) every time they change system fonts?\r\nNo, no, not at all!\r\n\r\nBTW I've concerned that viewer wouldn't show Hindi or Thai language, although Hindi is 4th language having native speakers on the earth. ( https://en.wikipedia.org/wiki/List_of_languages_by_number_of_native_speakers )\r\n\r\nSL Viewer has an open source font collection named DejaVu included in resource folder which has version 2.3 covering 150 languages but it lacks many Asian languages like CJK or Indian languages.\r\nDejaVu doesn't have Thai font although description includes Thai.\r\nNow DejaVu is version 2.35, a few languages had added.\r\nIt's time to replace DejaVu fonts. (http://dejavu-fonts.org/wiki/Download )\r\n\r\nThere are some open source Asian fonts now, SL viewer should bundle these fonts.\r\nI listed up fonts to be inculded, chose them to cover top 25 languages.\r\nThey are released under SIL Open Font License or Apache License.\r\n\r\nNotoSansBengali-Regular.ttf\r\nNotoSansDevanagari-Regular.ttf\r\nNotoSansGurmukhi-Regular.ttf\r\nNotoSansTamil-Regular.ttf\r\nNotoSansTelugu-Regular.ttf\r\nNotoSansThai-Regular.ttf\r\nDroidSansFallback.ttf\r\n\r\nI made a patch including these fonts with updated fonts.xml.\r\nNew fonts.xml includes font settings for these fonts, and replaced fallback font settings only have Arial Unicode.\r\nArial Unicode is included in MS Office or Mac OS X, covers 172 languages but not open source so we can't bundle it in our viewer (and so large, 23Mbytes).\r\n\r\nNotoSans fonts are from https://github.com/googlei18n/noto-fonts/tree/master/hinted \r\nDroidSansFallback is from repository for Android OS: https://android.googlesource.com/platform/frameworks/base/\r\n\r\nThere are Noto CJK fonts but so large file size, about 16Mbytes each Chinese, Japanese and Korean but DroidSansFallback.ttf is only 3.5Mbytes including CJK in one file.\r\n\r\nAfter this modification, we can see 169 languages in 184 defined in ISO 639-1.\r\nIf you have Arial Unicode in your system folder, it increases to 175 languages.\r\nViewer size will grow a bit(about 4Mbytes), but it is worth to do it.\r\n\r\nPlease apply this patch as soon as possible, Oz.\r\nAfter that, you never get this kind of trouble. (except CEF viewer:P)", 'ReOpened Count': 0.0, 'Severity': 'Unset', 'System': 'SL Viewer', 'Target Viewer Version': 'viewer-development', 'What just happened?': 'CJK, Indian or Thai characters are displayed as boxes (tofu)', 'What were you doing when it happened?': 'Typing or pasting some Asian characters in input field or notecard.', 'What were you expecting to happen instead?': 'These language are displayed as it be', 'Where': 'Everywhere', } ```
sl-service-account commented 9 years ago

Kyle Linden commented at 2015-10-12T18:00:45Z

Hello Pell,

Thank you for reporting this issue with a patch. It is a duplicate of an issue already reported. I will update the team and let them know you have included a patch.

Thank you