Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » scout » How I can localize texts in ui javascript (frontend)
How I can localize texts in ui javascript (frontend) [message #1816988] Wed, 13 November 2019 12:53 Go to next message
Miloslav Frajdl is currently offline Miloslav FrajdlFriend
Messages: 14
Registered: June 2018
Junior Member
Hello.

I have classic Scout application where I localized all texts with Texts.nls. This operates only in content generated with Java code.

But the application contains other texts that are not translated. For example "... rows loaded", "Reload data", all texts in table customize, in standard dialog boxes etc. These texts are in my opinion generated by Javascript.

How (where) I can translate these texts?

Thank you for your advice.
Re: How I can localize texts in ui javascript (frontend) [message #1816989 is a reply to message #1816988] Wed, 13 November 2019 13:11 Go to previous messageGo to next message
Andre Wegmueller is currently offline Andre WegmuellerFriend
Messages: 91
Registered: September 2012
Location: Baden-Dättwil, Switzerla...
Member
Hi Miloslav

Some texts in Scout are part of the framework, like the texts you mentioned in your post. Scout uses a resource bundle for these texts. Its located in the module "org.eclipse.scout.rt.ui.html" at this location on the class-path: "org\eclipse\scout\rt\ui\html\Texts.properties". Since Scout is developed in Switzerland we currently only provide English, German, French and Italian texts. However, when you provide a properties file for the Locale you're missing, Scout should use the texts from there, instead of the English texts (which are used by default, when no Locale matches).

For instance "Texts_es.properties" would add Spanish texts. Make sure the file is on the same location on the class-path like the other .properties files (see further above).

Btw: when you make a translation of these texts, please submit a pull request on GitHub, so Scout can support more languages out-of-the-box.

Cheers,
André


Eclipse Scout Homepage | Documentation | GitHub
Re: How I can localize texts in ui javascript (frontend) [message #1817003 is a reply to message #1816989] Wed, 13 November 2019 15:50 Go to previous message
Miloslav Frajdl is currently offline Miloslav FrajdlFriend
Messages: 14
Registered: June 2018
Junior Member
Thank you very much.
Previous Topic:Re-use Table class used in TablePage and in Form
Next Topic:Get data for form from database
Goto Forum:
  


Current Time: Wed Apr 01 19:03:07 GMT 2020

Powered by FUDForum. Page generated in 0.02050 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top