Re: Integrate ITS Tool with gettext and Autotools
- From: Daiki Ueno <ueno gnu org>
- To: desktop-devel-list gnome org
- Subject: Re: Integrate ITS Tool with gettext and Autotools
- Date: Thu, 08 Oct 2015 18:51:59 +0900
Sébastien Wilmet <swilmet gnome org> writes:
I don't think gettext's XML support will grow to the point where it can
handle complex documentation, but this is probably the way forward for
simple XML data files.
I plan to include it in the next release of gettext (maybe in December),
and at some point, I will ask maintainers of custom XML formats to
consider installing their rule files in $prefix/share/gettext/its.
For details, see the preliminary documentation available at:
gettext itself will ship some by default:
This is merely for compatibility reasons, and it would be nicer if those
files are maintained in the relevant "upstream" projects.
To mark XML attributes as translatable, a common thing to do is to
prefix them with an underscore. Intltool supports that, but not gettext
AFAIK. If the ITS branch supports that, it would cover lots of simple
It sounds to me one step back, since it typically involves unnecessary
intermediate files (*.in, *.in.in, ...) or a special treatment of
underscores in your XML parser. On the other hand, it can be easily
written as an ITS rule:
<its:translateRule selector="//*[starts-with(name(.), '_')]" translate="yes"/>
For those curious about the current status, I have created a Fedora Copr
repository, which will be kept updated until it gets merged:
Comments and suggestions would be appreciated.
] [Thread Prev