Oxygen language for localization

Post here questions and problems related to oXygen frameworks/document types.
patrick
Posts: 96

Oxygen language for localization

Wed Jul 08, 2015 4:23 pm

Hi,

I localize my plugins using

Code: Select all

static final ResourceBundle locale = ResourceBundle.getBundle("locale");


But how can I consider the language selection from Oxygen Editor instead the system setting?

Best regards,
Patrick
Radu
Posts: 5689

Re: Oxygen language for localization

Wed Jul 08, 2015 4:30 pm

Hi Patrick,

You could try to use the API:

Code: Select all

ro.sync.exml.workspace.api.PluginWorkspaceProvider.getPluginWorkspace().getUserInterfaceLanguage()


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

Re: Oxygen language for localization

Thu Jul 16, 2015 4:44 pm

I had no luck trying to set the correct language. Do you have an example how it's solved in oxygen?

Another question about loclizsation: I can translate the actions but not the css and xslt titles. Is it possible to translate those entries to get an fully localized framework?

Thanks
Patrick
Radu
Posts: 5689

Re: Oxygen language for localization

Fri Jul 17, 2015 8:37 am

Hi Patrick,

I had no luck trying to set the correct language. Do you have an example how it's solved in oxygen?


I'm sorry but I do not quite understand your setup. Please give me more details. Are you working with a plugin, with a framework or both? The API I gave you was to find out the application language used by Oxygen. Does it not work for you or are you having another use case?
If you work on the framework level you can use the internationalization support we have at framework level:

http://www.oxygenxml.com/doc/versions/17.0/ug-editor/#topics/localizing_frameworks.html

Unfortunately we do not have this support when creating a plugin. But you do have the API to access the current user interface language and you can create your own resources bundle.

Another question about localization: I can translate the actions but not the css and xslt titles. Is it possible to translate those entries to get an fully localized framework?


By css do you mean the titles for the alternate CSSs? Indeed, they cannot be localized but I could try and add an issue to fix this.
By XSLT titles do you mean the transformation scenario names? They are also not localized, maybe we could also consider localizing them.

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

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

Who is online

Users browsing this forum: No registered users and 2 guests