project-navigation
Personal tools

Author Topic: gettext in ufopedia  (Read 3712 times)

Hoehrer

  • Guest
gettext in ufopedia
« on: March 31, 2006, 02:04:59 pm »
Currently gettext for the ufopedia is implemented again (as good as i could do it), but the text isn't showing.

Code: [Select]
= cl_ufopedia.c ===============
...
menuText[TEXT_UFOPEDIA]=_(t->description);
...
===============================

"t-> description" stores e.g "assault_txt", so  it should be replaced with this text from en_GB.po (or de.po):
Code: [Select]
#~ msgid "assault_txt"
#~ msgstr ""
#~ "The AR-80 is the standard weapon of the GDF forces. Using improved ammo "
#~ "and a revolutionary\n"
#~ "design, this rifle can do more damage as any comparable assault rifle. "
#~ "The AR-80s rear loaded\n"
#~ "clip allows the weapon to fire with greater accuracy as the bullet has to "
#~ "move down an extended\n"
#~ "muzzle before exiting the weapon. The Assault Rifle can also be repaired "
#~ "much easier due to the\n"
#~ "fact that it is built in modules. For example, the firing mechanism can "
#~ "be field repaired simply\n"
#~ "by removing the out of commission back end and inserting a new one. The "
#~ "entire process takes\n"
#~ "only minutes."



What do i need to look at to get it working again?

Bug tracker:
http://sourceforge.net/tracker/index.php?func=detail&aid=1459715&group_id=157793&atid=805242

Werner

Offline Mattn

  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 4831
  • https://github.com/mgerhardy/vengi
    • View Profile
    • Vengi Voxel Tools
gettext in ufopedia
« Reply #1 on: April 07, 2006, 06:06:11 pm »
the i18n stuff works for me

Hoehrer

  • Guest
gettext in ufopedia
« Reply #2 on: April 07, 2006, 09:59:39 pm »
Quote from: "Mattn"
the i18n stuff works for me


It works for me as well ... except for the ufopedia texts (e.g _("_assault_txt") in code ->  "assault_txt" in po)
It now displays only the "assault_txt" (msgid) stuff instead of the defined msgstr. I dunno why, everything seems to be defined correctly.

Werner

Offline Mattn

  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 4831
  • https://github.com/mgerhardy/vengi
    • View Profile
    • Vengi Voxel Tools
gettext in ufopedia
« Reply #3 on: April 08, 2006, 07:04:54 am »
as i said- for me it works - maybe you have to make a local "make lang" in src/linux to update the mo files in base/i18n

Hoehrer

  • Guest
gettext in ufopedia
« Reply #4 on: April 08, 2006, 09:38:45 am »
Thanks, "make lang" did the job.

Werner