Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » I18 questions
I18 questions [message #136985] Thu, 18 June 2009 15:04 Go to next message
Aleksandar Pavlov is currently offline Aleksandar PavlovFriend
Messages: 79
Registered: July 2009
Member
Hi there, I have a few questions about Internationalization:

1. Can we set the prefered language programatically. That is, to read the
prefered language from the database and use the correct *.properties file.

2. Could the UI language be changed on the fly, without reload of the page.

3. What is the fastest and simplest method for externalization of strings
in already developed application you already know, step by step.

Thank you in advance
Re: I18 questions [message #137013 is a reply to message #136985] Thu, 18 June 2009 16:54 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: benjamin.wolff.web.de

Hi,

to 1.) did you take a look at RWT#setLocale() ?? that's how i do it.

to 2.) would be interesting, i couldn't figure out a way, i think this would require extensive listener usage?! in my application one can only set the language during login so i don't need on the fly language change, but it would be interesting indeed!

to 3.) sry, can't help you there, i developed with externalization, but did you check the i18n guide in the RAP developer guide?


greetings,
-ben



Aleksandar Pavlov schrieb:
> Hi there, I have a few questions about Internationalization:
>
> 1. Can we set the prefered language programatically. That is, to read
> the prefered language from the database and use the correct *.properties
> file.
>
> 2. Could the UI language be changed on the fly, without reload of the page.
>
> 3. What is the fastest and simplest method for externalization of
> strings in already developed application you already know, step by step.
>
> Thank you in advance
>
Re: I18 questions [message #137069 is a reply to message #137013] Fri, 19 June 2009 08:42 Go to previous messageGo to next message
Aleksandar Pavlov is currently offline Aleksandar PavlovFriend
Messages: 79
Registered: July 2009
Member
Thank you for the first point, that is the thing I am looking for.
On point 3), easier development process:
yes I have read it I also figured out to alter the result from the
eclipse externalizer with two regex-es:
### reg ex
# find: Messages\.getString\("(\w+)"\)
# repl: Messages.get().$1

and then CTRL+1 on each missing field in the Message class.
Hope that is good staring point for someone new.
But for me it is kind of frustrating yet.
That's why I am asking
Thanks again

Ben W. wrote:
> Hi,
>
> to 1.) did you take a look at RWT#setLocale() ?? that's how i do it.
>
> to 2.) would be interesting, i couldn't figure out a way, i think this
> would require extensive listener usage?! in my application one can only
> set the language during login so i don't need on the fly language
> change, but it would be interesting indeed!
>
> to 3.) sry, can't help you there, i developed with externalization, but
> did you check the i18n guide in the RAP developer guide?
>
>
> greetings,
> -ben
>
>
>
> Aleksandar Pavlov schrieb:
>> Hi there, I have a few questions about Internationalization:
>>
>> 1. Can we set the prefered language programatically. That is, to read
>> the prefered language from the database and use the correct
>> *.properties file.
>>
>> 2. Could the UI language be changed on the fly, without reload of the
>> page.
>>
>> 3. What is the fastest and simplest method for externalization of
>> strings in already developed application you already know, step by step.
>>
>> Thank you in advance
>>
Re: I18 questions [message #137436 is a reply to message #136985] Tue, 23 June 2009 15:41 Go to previous messageGo to next message
Aleksandar Pavlov is currently offline Aleksandar PavlovFriend
Messages: 79
Registered: July 2009
Member
Hi there,
New quick question:
How can I translate the labels of the buttons in the Wizards?
They seem to be always in English.
Thank you in advance
Re: I18 questions [message #137461 is a reply to message #137436] Tue, 23 June 2009 18:14 Go to previous messageGo to next message
Rüdiger Herrmann is currently offline Rüdiger HerrmannFriend
Messages: 581
Registered: July 2009
Senior Member
Did you read this?
http://dev.eclipse.org/newslists/news.eclipse.technology.rap /msg03169.html

Aleksandar Pavlov wrote:
> Hi there,
> New quick question:
> How can I translate the labels of the buttons in the Wizards?
> They seem to be always in English.
> Thank you in advance
Re: I18 questions [message #137496 is a reply to message #137461] Wed, 24 June 2009 07:53 Go to previous messageGo to next message
Aleksandar Pavlov is currently offline Aleksandar PavlovFriend
Messages: 79
Registered: July 2009
Member
No, I haven't. It's a good start
Anyways, here
http://download.eclipse.org/technology/babel/babel_language_ packs/ganymede.php
I see many packages.
I guess only a few are responsible for RAP. Is this one correct:
BabelLanguagePack-eclipse-de_3.4.0.v20090524043402.zip

And another question:
That seems like it is eclipse specific. I guess it will work when I have
my RAP application started in eclipse. But is it going to work when
exported to WAR file.

And one last thing: the cited thread ends with the most interesting
qustion unanswered: "In JFace all translated texts are in a
message.properties file. In RAP, there exists another file
dialogmessages.properties which contains labels for dialog buttons. So,
there must be a translated version of this property file in the fragment
which isn't the case in the original version."

Thank you

Rüdiger Herrmann wrote:
> Did you read this?
> http://dev.eclipse.org/newslists/news.eclipse.technology.rap /msg03169.html
>
> Aleksandar Pavlov wrote:
>> Hi there,
>> New quick question:
>> How can I translate the labels of the buttons in the Wizards?
>> They seem to be always in English.
>> Thank you in advance
Re: I18 questions [message #138167 is a reply to message #137496] Fri, 26 June 2009 11:31 Go to previous messageGo to next message
Rüdiger Herrmann is currently offline Rüdiger HerrmannFriend
Messages: 581
Registered: July 2009
Senior Member
Aleksandar Pavlov wrote:
> No, I haven't. It's a good start
> Anyways, here
> http://download.eclipse.org/technology/babel/babel_language_ packs/ganymede.php
> I see many packages.
> I guess only a few are responsible for RAP. Is this one correct:
> BabelLanguagePack-eclipse-de_3.4.0.v20090524043402.zip
If you open it, you will see. There should be fragments for the
plug-ins that you whish to have translations for.
E.g. org.elclipse.jface.nl_ar contains Arabic translations for
plug-in org.eclipse.jface.

>
> And another question:
> That seems like it is eclipse specific. I guess it will work when I have
> my RAP application started in eclipse. But is it going to work when
> exported to WAR file.
I am afraid, but I don't understand. *what* will work?
Translations work from within the IDE and when deployed. Of course
you need to include the fragments in your launch configuration.

Please make sure you read the documentation:
http://help.eclipse.org/galileo/index.jsp?topic=/org.eclipse .rap.help/help/html/advanced/internationalization.html

>
> And one last thing: the cited thread ends with the most interesting
> qustion unanswered: "In JFace all translated texts are in a
> message.properties file. In RAP, there exists another file
> dialogmessages.properties which contains labels for dialog buttons. So,
> there must be a translated version of this property file in the fragment
> which isn't the case in the original version."
Which "cited thread" do your refer to?

>
> Thank you
>
> Rüdiger Herrmann wrote:
>> Did you read this?
>> http://dev.eclipse.org/newslists/news.eclipse.technology.rap /msg03169.html
>>
>> Aleksandar Pavlov wrote:
>>> Hi there,
>>> New quick question:
>>> How can I translate the labels of the buttons in the Wizards?
>>> They seem to be always in English.
>>> Thank you in advance
>
Re: I18 questions [message #138175 is a reply to message #138167] Fri, 26 June 2009 11:34 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: benjamin.wolff.web.de

hi,

i think he's refering to this post: http://dev.eclipse.org/newslists/news.eclipse.technology.rap /msg03307.html

the question remains very interesting indeed :)

greetings,
-ben

Rüdiger Herrmann schrieb:
> Aleksandar Pavlov wrote:
>> No, I haven't. It's a good start
>> Anyways, here
>> http://download.eclipse.org/technology/babel/babel_language_ packs/ganymede.php
>>
>> I see many packages.
>> I guess only a few are responsible for RAP. Is this one correct:
>> BabelLanguagePack-eclipse-de_3.4.0.v20090524043402.zip
> If you open it, you will see. There should be fragments for the plug-ins
> that you whish to have translations for.
> E.g. org.elclipse.jface.nl_ar contains Arabic translations for plug-in
> org.eclipse.jface.
>
>>
>> And another question:
>> That seems like it is eclipse specific. I guess it will work when I have
>> my RAP application started in eclipse. But is it going to work when
>> exported to WAR file.
> I am afraid, but I don't understand. *what* will work?
> Translations work from within the IDE and when deployed. Of course you
> need to include the fragments in your launch configuration.
>
> Please make sure you read the documentation:
> http://help.eclipse.org/galileo/index.jsp?topic=/org.eclipse .rap.help/help/html/advanced/internationalization.html
>
>
>>
>> And one last thing: the cited thread ends with the most interesting
>> qustion unanswered: "In JFace all translated texts are in a
>> message.properties file. In RAP, there exists another file
>> dialogmessages.properties which contains labels for dialog buttons. So,
>> there must be a translated version of this property file in the fragment
>> which isn't the case in the original version."
> Which "cited thread" do your refer to?
>
>>
>> Thank you
>>
>> Rüdiger Herrmann wrote:
>>> Did you read this?
>>> http://dev.eclipse.org/newslists/news.eclipse.technology.rap /msg03169.html
>>>
>>>
>>> Aleksandar Pavlov wrote:
>>>> Hi there,
>>>> New quick question:
>>>> How can I translate the labels of the buttons in the Wizards?
>>>> They seem to be always in English.
>>>> Thank you in advance
>>
Re: I18 questions [message #138218 is a reply to message #138175] Fri, 26 June 2009 12:58 Go to previous messageGo to next message
Rüdiger Herrmann is currently offline Rüdiger HerrmannFriend
Messages: 581
Registered: July 2009
Senior Member
Ben W. wrote:
> hi,
>
> i think he's refering to this post:
> http://dev.eclipse.org/newslists/news.eclipse.technology.rap /msg03307.html
>
> the question remains very interesting indeed :)
Ah, thanks for the hint (I didn't get that).

The dialogmessages.properties is a left-over that can now probably
merged back into the original JFace messages.properties.
To make the IDialogConstants interface work for RAP we hand to
convert it into a class to be able to have multiple instances for
the multiple locales. The easies solution back then was to re-use
the RWT NLS mechanism.
Feel free to file a bugzila.

>
> greetings,
> -ben
>
> Rüdiger Herrmann schrieb:
>> Aleksandar Pavlov wrote:
>>> No, I haven't. It's a good start
>>> Anyways, here
>>> http://download.eclipse.org/technology/babel/babel_language_ packs/ganymede.php
>>>
>>> I see many packages.
>>> I guess only a few are responsible for RAP. Is this one correct:
>>> BabelLanguagePack-eclipse-de_3.4.0.v20090524043402.zip
>> If you open it, you will see. There should be fragments for the
>> plug-ins that you whish to have translations for.
>> E.g. org.elclipse.jface.nl_ar contains Arabic translations for plug-in
>> org.eclipse.jface.
>>
>>>
>>> And another question:
>>> That seems like it is eclipse specific. I guess it will work when I have
>>> my RAP application started in eclipse. But is it going to work when
>>> exported to WAR file.
>> I am afraid, but I don't understand. *what* will work?
>> Translations work from within the IDE and when deployed. Of course you
>> need to include the fragments in your launch configuration.
>>
>> Please make sure you read the documentation:
>> http://help.eclipse.org/galileo/index.jsp?topic=/org.eclipse .rap.help/help/html/advanced/internationalization.html
>>
>>
>>>
>>> And one last thing: the cited thread ends with the most interesting
>>> qustion unanswered: "In JFace all translated texts are in a
>>> message.properties file. In RAP, there exists another file
>>> dialogmessages.properties which contains labels for dialog buttons. So,
>>> there must be a translated version of this property file in the fragment
>>> which isn't the case in the original version."
>> Which "cited thread" do your refer to?
>>
>>>
>>> Thank you
>>>
>>> Rüdiger Herrmann wrote:
>>>> Did you read this?
>>>> http://dev.eclipse.org/newslists/news.eclipse.technology.rap /msg03169.html
>>>>
>>>>
>>>> Aleksandar Pavlov wrote:
>>>>> Hi there,
>>>>> New quick question:
>>>>> How can I translate the labels of the buttons in the Wizards?
>>>>> They seem to be always in English.
>>>>> Thank you in advance
>>>
Re: I18 questions [message #139047 is a reply to message #138218] Thu, 02 July 2009 16:16 Go to previous message
Eclipse UserFriend
Originally posted by: benjamin.wolff.web.de

hi,

i filed a bug: https://bugs.eclipse.org/bugs/show_bug.cgi?id=282307

greetings,
ben



Rüdiger Herrmann schrieb:
> Ben W. wrote:
>> hi,
>>
>> i think he's refering to this post:
>> http://dev.eclipse.org/newslists/news.eclipse.technology.rap /msg03307.html
>>
>>
>> the question remains very interesting indeed :)
> Ah, thanks for the hint (I didn't get that).
>
> The dialogmessages.properties is a left-over that can now probably
> merged back into the original JFace messages.properties.
> To make the IDialogConstants interface work for RAP we hand to convert
> it into a class to be able to have multiple instances for the multiple
> locales. The easies solution back then was to re-use the RWT NLS mechanism.
> Feel free to file a bugzila.
>
>>
>> greetings,
>> -ben
>>
>> Rüdiger Herrmann schrieb:
>>> Aleksandar Pavlov wrote:
>>>> No, I haven't. It's a good start
>>>> Anyways, here
>>>> http://download.eclipse.org/technology/babel/babel_language_ packs/ganymede.php
>>>>
>>>> I see many packages.
>>>> I guess only a few are responsible for RAP. Is this one correct:
>>>> BabelLanguagePack-eclipse-de_3.4.0.v20090524043402.zip
>>> If you open it, you will see. There should be fragments for the
>>> plug-ins that you whish to have translations for.
>>> E.g. org.elclipse.jface.nl_ar contains Arabic translations for
>>> plug-in org.eclipse.jface.
>>>
>>>>
>>>> And another question:
>>>> That seems like it is eclipse specific. I guess it will work when I
>>>> have
>>>> my RAP application started in eclipse. But is it going to work when
>>>> exported to WAR file.
>>> I am afraid, but I don't understand. *what* will work?
>>> Translations work from within the IDE and when deployed. Of course
>>> you need to include the fragments in your launch configuration.
>>>
>>> Please make sure you read the documentation:
>>> http://help.eclipse.org/galileo/index.jsp?topic=/org.eclipse .rap.help/help/html/advanced/internationalization.html
>>>
>>>
>>>>
>>>> And one last thing: the cited thread ends with the most interesting
>>>> qustion unanswered: "In JFace all translated texts are in a
>>>> message.properties file. In RAP, there exists another file
>>>> dialogmessages.properties which contains labels for dialog buttons. So,
>>>> there must be a translated version of this property file in the
>>>> fragment
>>>> which isn't the case in the original version."
>>> Which "cited thread" do your refer to?
>>>
>>>>
>>>> Thank you
>>>>
>>>> Rüdiger Herrmann wrote:
>>>>> Did you read this?
>>>>> http://dev.eclipse.org/newslists/news.eclipse.technology.rap /msg03169.html
>>>>>
>>>>>
>>>>> Aleksandar Pavlov wrote:
>>>>>> Hi there,
>>>>>> New quick question:
>>>>>> How can I translate the labels of the buttons in the Wizards?
>>>>>> They seem to be always in English.
>>>>>> Thank you in advance
>>>>
>
Previous Topic:verifyEvent.doit = false does not work
Next Topic:Multitab support
Goto Forum:
  


Current Time: Fri Mar 29 00:28:41 GMT 2024

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

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

Back to the top