[Kde-games-devel] kde game and i18n
Kleag
kleag at free.fr
Tue Aug 16 13:23:51 CEST 2005
Hello,
I don't know how to handle i18n in network mode for my game KsirK: I forge
messages in a client to be displayed, internationalized, in all other
clients. I made a special container class that is filled with not i18ned
messages parts. These parts are then transmitted over the network with
KGame::sendMessage and they are then extracted and given to the i18n(...)
function.
There is problems with this approach:
1. I was not able to find the i18n() function definition, so I'm not sure that
it will be able to translate strings given at runtime;
2. I don't know how to mark strings in my code to be extracted by the tool
that makes the .pot file;
3. With this method, I cannot write strings to be translated like that: '...
("ABC %1 XYZ").arg(t)' but I have to write '... << "ABC " << t << " XYZ"
which does not allow a good translation as soon as there is words order
changes between languages.
Does anyone know how to cleanly handle i18n of strings in sent to different
languages clients ?
Thanks in advance.
Kleag
--
KsirK - a turn-based strategy game for KDE
http://gna.org/projects/ksirk
KGraphViewer - a GraphViz dot graphs viewer
http://gna.org/projects/kgraphviewer
More information about the kde-games-devel
mailing list