Lokalization for KDE AppStream AppData files

Albert Astals Cid aacid at kde.org
Sun Feb 23 14:44:32 GMT 2014


El Divendres, 21 de febrer de 2014, a les 16:48:01, Matthias Klumpp va 
escriure:
> 2014-02-21 2:02 GMT+01:00 Aleix Pol <aleixpol at kde.org>:
> > [...]
> > 
> > I'm very happy to see you pushing this forward. Muon will be supporting
> > this format from the next released version (to some extent) and I'm sure
> > this will increase over time.
> 
> Great! Please keep in mind that the format is not meant to be
> processed directly, but instead an intermediate Xapian database is
> used. GNOME does not use it because the library for accessing the db
> was not ready in time and it only had to run on Fedora anyway at that
> time.
> I will hopefully have time to work on the database stuff this weekend.
> 
> > Regarding localization, Albert is the man here. If he says it's done in a
> > way, you do it this way. ;-)
> > More seriously though, I agree that it's doesn't make much sense to have
> > it
> > generated at build time, since this would require having all translations
> > installed. Maybe we can figure out a mechanism appdata -> po -> appdata
> > like in the desktop files. It works great there for desktop files, and
> > it's the exact same use-case.
> 
> I have a compromise to offer, which will be necessary anyway in a way,
> since to-be-localized entries in our XML files would have to be
> prefixed with an underscore, so merging stuff back into the original
> file does not work (unless we duplicate data there, which is ugly).
> So, new suggestion:
>  * Project author creates file project.appdata.xml.in, containing the
> raw data which has to be translated.
>  * Scripty processes that file and commits a project.appdata.xml file
> in the same directory where the previous one was, containing all
> localizations. If one is already there, the file is updated.
>  * We simply install the localized file and keep the other one as template
> That solution would work, I would be happy with it and hopefully
> Albert as well :-) If not, please make an alternative suggestion.

Why do you need two files instead of one file like we do for .desktop files?

Cheers,
  Albert

> Cheers,
>     Matthias





More information about the kde-core-devel mailing list