Difference between revisions of "User:Masao/i18n"
Jump to navigation
Jump to search
(Login.jspf and images) |
(Notes on RBE) |
||
(2 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
At first, I made some of Japanese resources for PubMan on 2008-09-22. | |||
Later on 2008-12-25, I switched the codebase into the new R4 GUI. | |||
==Howto== | ==Howto== | ||
Line 11: | Line 12: | ||
(maybe no need to work right now...) | (maybe no need to work right now...) | ||
===pubman_presentation/src/main/webapp/desktop/Login.jspf=== | ===(R3) pubman_presentation/src/main/webapp/desktop/Login.jspf=== | ||
Add a locale switch link for new language. | Add a locale switch link for new language. | ||
====(R3)pubman_presentation/src/main/webapp/image==== | |||
====pubman_presentation/src/main/webapp/image==== | |||
Current implementation needs the national flag for the language. (really?) | Current implementation needs the national flag for the language. (really?) | ||
Line 22: | Line 22: | ||
I got an image of the PD Japanese flag from WM, and modified it for the desired size (currently 30x15). | I got an image of the PD Japanese flag from WM, and modified it for the desired size (currently 30x15). | ||
===pubman_presentation/src/main/resources/{Message,Label}_ja.properties=== | |||
===(R4) pubman_presentation/src/main/webapp/header/ui/MetaMenu.jspf=== | |||
Add a locale switch link for new language. | |||
===pubman_presentation/src/main/resources/{Message,Label,Tooltips}_ja.properties=== | |||
Copy from each "*_en" into "*_ja" properties files, and then add Japanese translations for labels/messages. | Copy from each "*_en" into "*_ja" properties files, and then add Japanese translations for labels/messages. | ||
;Note1:Java does not support native encodings of Japanese characters even in UTF-8. You need to use unicode-escaping such as <code>\uXXXX</code>. The "native2ascii" utility work for that purpose, but [http://propedit.sourceforge.jp/ PropertyEditor plugin for eclipse] works fine. | |||
;Note2: [http://sourceforge.net/projects/eclipse-rbe/ ResourceBundleEditor for Eclipse] will be usefull for i18n of resource bundle editor. Note that this editor always re-sorts the keys alphabetically every time when saving files. As of January 2009, it is agreed that all developers should use RBE in order to avoid conficts when merge. |
Latest revision as of 13:53, 13 February 2009
At first, I made some of Japanese resources for PubMan on 2008-09-22. Later on 2008-12-25, I switched the codebase into the new R4 GUI.
Howto[edit]
pubman_presentation/src/main/webapp/WEB-INF/faces-config.xml[edit]
Add the following line in the <locale-config> element:
<supported-locale>ja</supported-locale>
pubman_presentation/src/main/java/de/mpg/escidoc/pubman/util/InternationalizationHelper.java[edit]
Add information for a link to language-specific helps. (maybe no need to work right now...)
(R3) pubman_presentation/src/main/webapp/desktop/Login.jspf[edit]
Add a locale switch link for new language.
(R3)pubman_presentation/src/main/webapp/image[edit]
Current implementation needs the national flag for the language. (really?) Put the image file here, and link to it from the jspf.
I got an image of the PD Japanese flag from WM, and modified it for the desired size (currently 30x15).
(R4) pubman_presentation/src/main/webapp/header/ui/MetaMenu.jspf[edit]
Add a locale switch link for new language.
pubman_presentation/src/main/resources/{Message,Label,Tooltips}_ja.properties[edit]
Copy from each "*_en" into "*_ja" properties files, and then add Japanese translations for labels/messages.
- Note1
- Java does not support native encodings of Japanese characters even in UTF-8. You need to use unicode-escaping such as
\uXXXX
. The "native2ascii" utility work for that purpose, but PropertyEditor plugin for eclipse works fine.
- Note2
- ResourceBundleEditor for Eclipse will be usefull for i18n of resource bundle editor. Note that this editor always re-sorts the keys alphabetically every time when saving files. As of January 2009, it is agreed that all developers should use RBE in order to avoid conficts when merge.