java - Eclipse RCP Internationalization separate plugin -


no tutorial presents concrete example of how internationalization plug-in fragment created used. need translations plugin.xml's , source code files. trying wrap head around translations go, , i18n facade goes.

1. how fragment apply multi-plugin enterprise application, , more importantly, how plugins externalize strings inside appropriate folders in fragment?

2. what external jars? how mechanism provide translation support external resources?

3. risk of being long-shot, possible provide independent translation of view or perspective? not @ runtime, because know bundles can't dynamically switched.

there available, this article lists process. it's based on eclipse 2.0 (!) basic ideas still correct. better article this tutorial vogella

  1. for each plugin need translate, create 1 plugin fragment. fragment associated 1 host plugin, need several fragments. each fragment can contain several languages though. languages separated folder structure described in step 5 in first article

  2. i guessing referring non-eclipse java jars have made yourself, yes? if so, completly different process, best suited separate question java tag. oracle has guide may help. keep in mind need translate content user exposed to. refactor keep user visible strings eclipse plugins might idea.

  3. are referring name of view/perspective? if so, yes. can translate information give in plugin.xml aswell. see vogellas article, chapter 3

edit:

at nr.3 referring choosing view translate (e.g. via view menu), restart app, said view should translate

well.. think of way work in theory, i'm not sure best alternative. translatation based on locale. , given locale translation chosen. if no appropriate translation exists, default selected.

so if view menu change locale of application to, "us-en-v1", , had 1 view had translation locale "us-en-v1", mean particular view translated, rest of application use default (could default closest translation, dont remember exactly).

then each view create new translation , use unique locale each.

that should work, abuses way translations supposed work, lead issues.

i've done similar @ 1 time, 1 app used in same language different customers had different vocabulary. used i18n make application use right terms defining our own locales.


Comments

Popular posts from this blog

css - Which browser returns the correct result for getBoundingClientRect of an SVG element? -

gcc - Calling fftR4() in c from assembly -

Function that returns a formatted array in VBA -