Lokalization for KDE AppStream AppData files
Kevin Krammer
krammer at kde.org
Wed Feb 26 09:24:44 GMT 2014
On Wednesday, 2014-02-26, 07:46:07, Martin Gräßlin wrote:
> On Tuesday 25 February 2014 23:20:18 Matthias Klumpp wrote:
> > No, it takes
> > <p>foo bar</p>
> > and turns that into
> > <p>foo bar</p>
> > <p lang="en">foo bar</p>
> > <p lang="de">föö bär</p>
> > <p lang="fr">le fó et la bàr</p>
> > <p lang="es">el fobarro</p>
> >
> > > intltool/itstool /can/ select "<p lang="x">foo bar</p>" as translation
> > > source, correct?
> >
> > The only use <p> or, in intltool's case every tag prefixed with an
> > underscore, like <_p>.
>
> What about we add an xslt processor before it's passed to intltool/itstool
> to format the xml as we need it. It's extremely trivial to pick all <p>
> with an argument and delete them or rename one to <_p>. And that should not
> even be a lot of work.
>
> I'm clearly voting for "let's make the tool to work with our workflow"
> instead of translating to another file. This would result in a mess...
Agreed, I was thinking the same.
My understanding is that the itstool can handle valid files, it just needs the
translations stripped from its input.
And removing all tags that have a "lang" attribute should indeed be doable.
This will result in exactly the same situation we have for .desktop files:
* the file starts with just the source langiage
* the translated entries get merged in automatically
* the translation source are the entries without language "marker", developer
edit only those
* process takes care of only considering source entries when updating
translator files
Cheers,
Kevin
--
Kevin Krammer, KDE developer, xdg-utils developer
KDE user support, developer mentoring
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20140226/4cc82136/attachment.sig>
More information about the kde-core-devel
mailing list