Add new languages in oxygen-xercesImpl jar

Post here questions and problems related to oXygen frameworks/document types.
Isabelle
Posts: 20

Add new languages in oxygen-xercesImpl jar

Wed Jan 17, 2018 6:46 pm

Hello,

We use oxygen-18.1.0.0.jar, and we need to add the Portuguese, Spanish and Chinese language to our application.
That is why we updated the jar oxygen-xercesImpl in order to have the xml errors messages in this new languages.

Spanish and Portuguese works fine but not Chinese.
The Chinese characters are replaced by special characters.

For exemple, when we want to show the message :
cvc-complex-type.2.4.a: Invalid content was found starting with element 'XXX'. One of '{XXX}' is expected.

It shows
cvc-complex-type.2.4.a: 从元素 'XXX' 开始,找到无效内容。其中一个 '{XXX}' 是预期的。
Instead of
cvc-complex-type.2.4.a: 从元素 'XXX' 开始,找到无效内容。其中一个 '{XXX}' 是预期的。

The Chinese properties file is encoded in UTF-8.

Can you tell me if there is a solution to show Chines characters and not special characters?
Thank you.

Regards,
Isabelle
Radu
Posts: 5257

Re: Add new languages in oxygen-xercesImpl jar

Thu Jan 18, 2018 9:22 am

Hi Isabelle,

About this remark:

The Chinese properties file is encoded in UTF-8.


This is wrong, properties files have a fixed encoding of ISO-8859-1. In the main Oxygen JAR there is an "Messages_ja_JP.properties", you can look at that to see how it looks like.
All characters which cannot be encoded with ISO-8859-1 need to be escaped. There are special properties file editors available for download. Also Oxygen 19.1 can automatically escape characters when saving a .properties file.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
Isabelle
Posts: 20

Re: Add new languages in oxygen-xercesImpl jar

Thu Jan 18, 2018 6:49 pm

Hello Radu,

We have fixed the encoding of the file and escaped characters and it works fine now.
Thank you for your help.

Regards,
Isabelle

Return to “SDK-API, Frameworks - Document Types”

Who is online

Users browsing this forum: No registered users and 1 guest