[Kde-games-devel] i18n issues in kf5 kdegames
Burkhard Lück
lueck at hube-lueck.de
Thu May 28 12:35:04 UTC 2015
Hi,
the kdegames in kf5 have some untranslated strings in the GUI.
Try e.g. KPat in a locale !=en_US and you will see the untranslated string
"Move" in the menu.
The string "Move" is in the KXmlGui (.rc) file kpatui.rc and extracted to the
catalog KPat, but there is only a query for the translation of "Move" with the
wrong domain "kxmlgui5".
Reason for that is the usage of
add_definitions(-DTRANSLATION_DOMAIN="kpat") in CMakeLists.txt
instead of
KLocalizedString::setApplicationDomain("kpat"); in a .cpp file
for applications.
See also http://api.kde.org/frameworks-api/frameworks5-apidocs/ki18n/html/prg_guide.html
Attached a patch to fix this issue for KPat, but nearly all games are affected:
~/src/kdegames$ wcgrep TRANSLATION_DOMAIN
./kbreakout/CMakeLists.txt:36:add_definitions(-DTRANSLATION_DOMAIN="kbreakout")
./kblackbox/CMakeLists.txt:31:add_definitions(-DTRANSLATION_DOMAIN="kblackbox")
./katomic/CMakeLists.txt:36:add_definitions(-DTRANSLATION_DOMAIN="katomic")
./granatier/CMakeLists.txt:36:add_definitions(-DTRANSLATION_DOMAIN="granatier")
./kshisen/CMakeLists.txt:31:add_definitions(-DTRANSLATION_DOMAIN="kshisen")
./bomber/CMakeLists.txt:32:add_definitions(-DTRANSLATION_DOMAIN="bomber")
./kapman/CMakeLists.txt:35:add_definitions(-DTRANSLATION_DOMAIN="kapman")
./kjumpingcube/CMakeLists.txt:38:add_definitions(-
DTRANSLATION_DOMAIN="kjumpingcube")
./kbounce/CMakeLists.txt:37:add_definitions(-DTRANSLATION_DOMAIN="kbounce")
./kfourinline/CMakeLists.txt:38:add_definitions(-
DTRANSLATION_DOMAIN="kfourinline")
./ksquares/CMakeLists.txt:36:add_definitions(-DTRANSLATION_DOMAIN="ksquares")
./kblocks/CMakeLists.txt:40:add_definitions(-DTRANSLATION_DOMAIN="kblocks")
./kdiamond/CMakeLists.txt:32:add_definitions(-DTRANSLATION_DOMAIN="kdiamond")
./killbots/CMakeLists.txt:37:add_definitions(-DTRANSLATION_DOMAIN="killbots")
./kollision/CMakeLists.txt:36:add_definitions(-DTRANSLATION_DOMAIN="kollision")
./klines/CMakeLists.txt:36:add_definitions(-DTRANSLATION_DOMAIN="klines")
Oh and kmines does not load its translation catalog "kmines" not at all
--
Burkhard Lück
-------------- next part --------------
A non-text attachment was scrubbed...
Name: kpat.diff
Type: text/x-patch
Size: 811 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-games-devel/attachments/20150528/19992725/attachment.bin>
More information about the kde-games-devel
mailing list