desktoptojson and list properties / i18n of JSON files

Albert Astals Cid aacid at kde.org
Thu Nov 20 22:35:47 GMT 2014


El Dijous, 20 de novembre de 2014, a les 18:13:04, Sebastian Kügler va 
escriure:
> On Wednesday, November 19, 2014 23:00:57 Albert Astals Cid wrote:
> > > So again, what is necessary to get this done?
> > 
> > Well, there's two steps about this:
> > 
> > 1) Know where the code is that gets the Name/Comment/Description from the
> > json
> 
> I don't understand this. What do you mean exactly?
> 
> > 2) Decide how you want to translate stuff (which may depend on 1)
> > 
> > For 2) there's broadly two options:
> > 2.1: Make the .json file have the translations and make sure the code from
> > 1  reads it properly
> > 2.2: Make the translations be in the .po and then make the code from 1
> > read
> > the english variant and call i18n(englishText)
> > 
> > 2.2 is easier (if possible to change the code in 1 to do it) since it does
> > not  involve writing back strings to the json file.
> 
> I'd prefer 2.1, since we have to write the json metadata into the plugins,
> so we'd have to assemble the original (untranslated) and translated data
> into one json structure anyway.

Actually it seems we already have the code reading from the generated json so 
yeah, 2.1 makes sense.

Cheers,
  Albert

> 
> Cheers,





More information about the kde-core-devel mailing list