Sjur Moshagen wrote:
>
> I'm starting on the next step to make the pdf plugin fully i18n -
> support for i18n text.
>
> To that extent I have a couple of questions:
>
> 1.
>
> In $FORREST_HOME/main/webapp/sitemap.xmap, the following lines are
> found:
>
> <map:transformer name="i18n"
> src="org.apache.cocoon.transformation.I18nTransformer">
> <catalogues default="common">
> <catalogue id="common" name="CommonMessages"
> location="{properties:skins-dir}common/translations"/>
> </catalogues>
> <cache-at-startup>true</cache-at-startup>
> </map:transformer>
>
> Why is the path to the message catalogue "soft-coded" to the project
> instead of using a LM?
When the locationmap was introduced we tried to
methodically go through all the plugins to
utilise the locationmaps. However, i don't recall
us doing that methodically in core. We need
another scan through everything.
> 2.
>
> Dispatcher has its own set of translations in
>
> $FORREST_HOME/whiteboard/plugins/o.a.f.plugin.internal.dispatcher/
> resources/stylesheets/common/translations/
>
> The files there seem to be exact copies of the ones in
>
> $FORREST_HOME/main/webapp/skins/common/translations/
>
> Any reason for the duplication? Why not use the skins catalogue?
There is a lot of stuff that got duplicated when
the dispatcher work started, e.g. sitemaps.
Not criticising, there seemed to be no other way.
I recall expressing concern over how to keep
stuff synchronised.
So anything that can be done to ease that is good.
> 3. Both dispatcher and skins seem to prefer translations in the
> project tree. Why is that? To ease setup for new languages for new
> users (understandable)? It would still be quite easy to use some LM to
> fall back to a message catalogue in forrest if not found in the
> project, and just tell users to copy the files into the proper project
> folder if needed (ie when needing support for a language not yet
> included in Forrest).
I suppose it is just the way that it evolved.
> Basic point for all these questions:
>
> now we have copies of the same info all over the place, and most is
> not used - I would like to remove all the unnecessary ones, and use LM
> in all cases - and remove the messages from the seed. As part of that
> I would like to update the user documentation for i18n as well, to
> make sure it reflects the current state and how to set up proper i18n
> support, as well as how to add new languages to the translation
> catalogue.
>
> WDYT?
I agree. Good on you for getting into this.
It is certainly needed.
-David