1

I'm developing a RCP Eclipse-based application and it makes use of the Eclipse providing tool, p2, as of Eclipse 3.4 (Ganymede).

The thing is, this application must be fully in Brazillian Portuguese, and it already is, except for the p2-related UI. And that's what I need to translate. How can I?

This is where I've been:

  1. Added the "updateMenu.label", "actionSets.softwareUpdates.label"... labels to my plugin.properties. Didn't work. I found out that this was related to the previous providing mechanism (Update Manager).
  2. Found the "message.properties" file inside the "org.eclipse.equinox.internal.p2.ui.sdk" package. Then created a copy of it on the root of my plugin folder, left only two keys and translated them. Didn't work. I guess either this is not possible or the new file should be placed under another folder?

So, I ask, is this even possible?

I still have two options in mind:

  1. Create a package with the same name of the p2 one inside my plugin and place the properties there
  2. Add a sufix to the file and change the locale of the application (it hasn't been done anywhere on the code since all the other messages are in Portuguese and it's a single-language application

Any suggestions?

All the best
-Alvaro C.

4

2 回答 2

2

您应该只添加一个片段项目来增强第三方插件的功能(这里是语言)。

1.创建一个片段项目

2.将您的第三方插件设置为“主机插件”

3.在这个片段中创建你的消息属性

编辑:有关一组现有翻译以及使用片段翻译 .properties 文件的示例,请参阅http://www.eclipse.org/babel/ 。

于 2012-06-15T12:19:06.743 回答
0

只需在 Eclipse 中使用正确的片段和包名称进行翻译,然后将翻译片段与您的产品一起导出,例如,如果产品依赖于特性,则将其包含到导出的特性中。

于 2013-03-20T12:24:44.887 回答