RFR: 8263140: Japanese chars garble in console window in HSDB

Yasumasa Suenaga ysuenaga at openjdk.java.net
Sun Mar 7 10:15:15 UTC 2021


We can command line debugger via "Windows" -> "Console" menu on HSDB. If the command shows error message in localized string (e.g. Japanese), it might garble as following:

![garbled](https://user-images.githubusercontent.com/7421132/110232635-39e89b00-7f62-11eb-95c9-1a5238072814.png)

Command line debugger and Debugger Console (WinDbg on Windows) will use Courier font on their console, but it does not show Japanese chars. I guess it would happen on CJK chars because monospaced font for Chinese, Japanese, Korean are different from Courier.

After this change on Windows which set to Japanese locale, it uses MS Gothic and we can see localized message as following:

![fixed](https://user-images.githubusercontent.com/7421132/110232699-a4014000-7f62-11eb-9185-6eff39394541.png)

-------------

Commit messages:
 - 8263140: Japanese chars garble in console window in HSDB

Changes: https://git.openjdk.java.net/jdk/pull/2862/files
 Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=2862&range=00
  Issue: https://bugs.openjdk.java.net/browse/JDK-8263140
  Stats: 8 lines in 3 files changed: 2 ins; 0 del; 6 mod
  Patch: https://git.openjdk.java.net/jdk/pull/2862.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/2862/head:pull/2862

PR: https://git.openjdk.java.net/jdk/pull/2862


More information about the serviceability-dev mailing list