[josm-dev] Wanted: Plugin Translation With Launchpad HowTo
Holger Mappt
holgerosm at gmx.net
Mon Dec 23 16:11:40 UTC 2013
On 22.12.2013 13:19, Dirk Stöcker wrote:
> On Sat, 21 Dec 2013, Holger Mappt wrote:
>
>> I copy the development.jar in the JOSM plugin directory
>> (~/.josm/plugins) and JOSM extracts some data like the icon. It
>> doesn't extract the translation (yet) if the plugin is not
>> installed
>
> You need to supply the translation in MANIFEST to make translation
> work in this case as well.
>
> http://josm.openstreetmap.de/wiki/DevelopersGuide/DevelopingPlugins#ThemanifestfileforaJOSMplugin
>
> Note, that actually the entry in the manifest is the only required
> one. Text in translation area for core or plugin are a workaround.
> OTOH the manifest entry is the only one, which gets not updated, as
> that would mean automatic changes to the build.xml and nobody wrote
> code to do so.
It's amazing how much details there are. I will look into the MANIFEST
translation update. What do you mean with "automatic changes to the
build.xml"? The file build.xml is changed automatically or something
should be added to build.xml that changes the MANIFEST?
I think the flow is like this:
* The description is added to the plugin josm.pot (taken from build.xml)
to add it to the translation chain. This is not necessary for automatic
translations (they could work with two runs, one for the strings
extracted from the code and one for the translation of the description),
but it's easier to have all strings together, e.g. in case someone wants
to do a manual translation (this is how you start before the plugin is
released).
* Merge with the JOSM PO files, strings needed for plugin remain.
* Translations for plugin description are extracted from PO files and
added to plugin MANIFEST.
* PO to *.lang conversion. The description could be removed before this
is done. But that removal would add more complexity with little gain.
Regards,
Holger
More information about the josm-dev
mailing list