[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Newsgroup Home]
|
[news.eclipse.platform.rcp] Re: How to i18n the perspective name?
|
- From: Daniel Krügler <dsp@xxxxxxx>
- Date: Fri, 10 Oct 2008 10:19:56 +0200
- Newsgroups: eclipse.platform.rcp
- Organization: EclipseCorner
- User-agent: Thunderbird 2.0.0.17 (Windows/20080914)
Daniel Krügler wrote:
Michael Obster wrote:
Hi,
I want to change the perspective name over a i18n. But how can I do
that? The view titles can be set with setPartName() from runtime, but
I didn't find a method to set the perspective name.
Is this only possible from plugin.xml? And how can I i18n this?
If you want to access the plugin.properties you can do so via
Platform.getResourceString(ThePlugin.getBundle(), "%resource-id");
The exist also methods to retrieve the Bundle object via id,
either via Platform or Bundle.
After an email communication with the OP I found out that I
misunderstood his question. Here is what I have learned so far,
but never tried that out:
1) The Manifest.MF file must contain the entry
Bundle-Localization: plugin
2) The plugin.xml entries which should be internationalized
have to be moved into the plugin.properties file and in the
plugin.xml the %key notation is used to get them from there.
3) Parallel to the plugin.properties you provide corresponding
plugin_${language_id}.properties files, where ${language_id}
is the corresponding Java language id. It is possible to
deploy these files in seperate fragments, but that should be
different from the actual problem.
HTH,
Daniel