Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Plugin Development Environment (PDE) » Why are properties translated in one project but not the other?
Why are properties translated in one project but not the other? [message #524149] Tue, 30 March 2010 22:39 Go to next message
Michael Moser is currently offline Michael MoserFriend
Messages: 914
Registered: July 2009
Senior Member
I have an odd effect, that I have two plugin projects with a plugin.xml and
plugin.properties file in each (one project was automatically created by the
EMF generator, the other is my own plugin).

For some odd reason, in the generated project all placeholders in the
properties.xml file are replaced by the corresponding values from the
..properties file, while in my own plugin this is not the case and all items
like perspective name, menu items, view category and name, etc. are always
labeled as "%placeHolderName", i.e. no properties-translation takes place.

Any idea, what could cause this? Is there some flag or option that needs to
be enabled in the project settings or programmatically to trigger this
..properties-translation? I compared all project settings in detail and
didn't find any difference that could explain this (to me at least...).

Michael
Re: Why are properties translated in one project but not the other? [message #524248 is a reply to message #524149] Wed, 31 March 2010 10:26 Go to previous messageGo to next message
Ralf Ebert is currently offline Ralf EbertFriend
Messages: 168
Registered: July 2009
Senior Member
Hi Michael,

> For some odd reason, in the generated project all placeholders in the
> properties.xml file are replaced by the corresponding values from the
> .properties file, while in my own plugin this is not the case and all
> items like perspective name, menu items, view category and name, etc.
> are always labeled as "%placeHolderName", i.e. no properties-translation
> takes place.

check the Bundle-Localization header in the MANIFEST.MF. If it's not specified, the
properties file has to be located at /OSGI-INF/l10n/bundle.properties. Before Eclipse 3.5
the default was to be at /plugin.properties. If you want this old behaviour, you have to
specify this in the manifest:

Bundle-Localization: plugin

Greetings,

Ralf


--
http://www.ralfebert.de/blog/eclipsercp/
Re: Why are properties translated in one project but not the other? [message #525566 is a reply to message #524248] Tue, 06 April 2010 21:41 Go to previous message
Michael Moser is currently offline Michael MoserFriend
Messages: 914
Registered: July 2009
Senior Member
"Ralf Ebert" <info@ralfebert.de> wrote in message
news:4BB32344.5090807@ralfebert.de...
> ...
> check the Bundle-Localization header in the MANIFEST.MF. If it's not
> specified, the properties file has to be located at
> /OSGI-INF/l10n/bundle.properties. Before Eclipse 3.5 the default was to be
> at /plugin.properties. If you want this old behaviour, you have to specify
> this in the manifest:
>
> Bundle-Localization: plugin

Aahh - *that* did the trick!

Thanks a lot!
Michael
Re: Why are properties translated in one project but not the other? [message #605328 is a reply to message #524149] Wed, 31 March 2010 10:26 Go to previous message
Ralf Ebert is currently offline Ralf EbertFriend
Messages: 168
Registered: July 2009
Senior Member
Hi Michael,

> For some odd reason, in the generated project all placeholders in the
> properties.xml file are replaced by the corresponding values from the
> .properties file, while in my own plugin this is not the case and all
> items like perspective name, menu items, view category and name, etc.
> are always labeled as "%placeHolderName", i.e. no properties-translation
> takes place.

check the Bundle-Localization header in the MANIFEST.MF. If it's not specified, the
properties file has to be located at /OSGI-INF/l10n/bundle.properties. Before Eclipse 3.5
the default was to be at /plugin.properties. If you want this old behaviour, you have to
specify this in the manifest:

Bundle-Localization: plugin

Greetings,

Ralf


--
http://www.ralfebert.de/blog/eclipsercp/
Re: Why are properties translated in one project but not the other? [message #605480 is a reply to message #524248] Tue, 06 April 2010 21:41 Go to previous message
Michael Moser is currently offline Michael MoserFriend
Messages: 914
Registered: July 2009
Senior Member
"Ralf Ebert" <info@ralfebert.de> wrote in message
news:4BB32344.5090807@ralfebert.de...
> ...
> check the Bundle-Localization header in the MANIFEST.MF. If it's not
> specified, the properties file has to be located at
> /OSGI-INF/l10n/bundle.properties. Before Eclipse 3.5 the default was to be
> at /plugin.properties. If you want this old behaviour, you have to specify
> this in the manifest:
>
> Bundle-Localization: plugin

Aahh - *that* did the trick!

Thanks a lot!
Michael
Previous Topic:Basic Editor Question
Next Topic:Export Product cannot find plugin
Goto Forum:
  


Current Time: Tue Mar 19 08:49:28 GMT 2024

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

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

Back to the top