Community
Participate
Working Groups
Build F2 Preferences>Java Select Installed JREs Standard VM(detected) string under Name column is corrupt in all languages. National characters are not displayed correctly at all. japanese reported this problem first, but says that most other countries have issues here... opened in response to TPRS ID=80
adjusted priority to P1
This dialog is contributed by JDT Debug.
Marking as F4 candidate
Could I get a screen shot showing the "corruption"? Looking at the code, I do not see where the problem is.
I have not seen the "corruption" yet, but for ARCH team approval, the consequence of not fixing this is that the VM name gets corrupted in the "Installed JRE" preference page.
Created attachment 1416 [details] Corruption in Japanese
If you do not read Japanese, you may not be able to identify from the picture that the Japanese is corrupted. The English string is "Standard VM (detected)". The Japanese string is corrupted because the characters are either not Japanese characters or are legitimate characters but have nothing to do with the word being translated, and are creating meaningless "words" in Japanese. In looking through the source files, it appears that the string "Standard VM (detected)" does not exist as a single string, but rather, as two different parts. At least, I could not find it as a single string. This is generally frowned upon for translatable strings, because other languages may need to change the order of words appearing in a string. When a string is built at run-time, that process is assigning a word order that is correct in English but is very likely to be incorrect in other languages. The preferred solution is to define complete strings for each phrase that will be needed so that each may be translated correctly. However, that may not be the problem here. There was something odd about the string lengths. If you can tell me which key(s) is/are being used to create "Standard VM (detected)" I might be able to give you more guidance.
Created attachment 1419 [details] French screen
Sorry, please ignore the French gif. I pasted it for the incorrect bug.
Released fix candiate fix to HEAD. Changed name of detected VM to "Detected VM". No longer performes concatenation of Strings. Changed property file String from "(detected)" to "Detected VM". Waiting for F4 approval.
*** Bug 20439 has been marked as a duplicate of this bug. ***
Verified.
This was not fixed. It looks OK only the first time you launch Workbench. Once you close and open it again, those strings are corrupted.
Verified that the problem exists as described. We've examined the vmConfiguration file in a binary editor and the bytes appear to be getting written correctly. Investigating the possibility that the problem may be in reading the file.
We have a fix in hand for this bug. In JavaRuntime, we weren't calling the InputStreamReader constructor which specifies a charset, so we were just getting the "default." The fix is to call the constructor that takes a charset and pass in UTF-8.
Fix has been released in JavaRuntime. The InputStreamReader created in JavaRuntime#loadVMConfiguration(File) is specified to use the "UTF-8" named charset. Please verify.
Placed change in 2.0.1 Branch