From 68d5713d99552d8178b02e40a1e262146c2dfb91 Mon Sep 17 00:00:00 2001 From: Christian Ohm Date: Tue, 20 Apr 2010 14:13:53 +0000 Subject: [PATCH] Make subtitles translateable, part I. Feed them through gettext on display, add the files to the update-po.sh script and run that to update POTFILES.in. Refs #1728. git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@10656 4a71c877-e1ca-e34f-864e-861f7616d084 --- po/POTFILES.in | 53 +++++++++++++++++++++++++++++++++++++++++++++++++ po/update-po.sh | 2 +- src/seqdisp.c | 2 +- 3 files changed, 55 insertions(+), 2 deletions(-) diff --git a/po/POTFILES.in b/po/POTFILES.in index 22cd0d145..945ac912b 100644 --- a/po/POTFILES.in +++ b/po/POTFILES.in @@ -84,6 +84,59 @@ data/base/script/text/tech.slo data/base/script/text/tutorial3.slo data/base/script/text/vtols2.slo data/base/script/text/vtols.slo +data/base/sequenceaudio/cam1/c001end.txt +data/base/sequenceaudio/cam1/c001.txa +data/base/sequenceaudio/cam1/c001.txt +data/base/sequenceaudio/cam1/cam1ccom.txt +data/base/sequenceaudio/cam1/cam1cnp.txt +data/base/sequenceaudio/cam1/cam1dnp.txt +data/base/sequenceaudio/cam1/cam1dp2.txt +data/base/sequenceaudio/cam1/cam1out2.txt +data/base/sequenceaudio/cam1/cam1out3.txt +data/base/sequenceaudio/cam1/cam1out4.txt +data/base/sequenceaudio/cam1/cam1out5.txt +data/base/sequenceaudio/cam1/map1a_c.txt +data/base/sequenceaudio/cam1/sub13np1.txt +data/base/sequenceaudio/cam1/sub13np2.txt +data/base/sequenceaudio/cam1/sub14anp.txt +data/base/sequenceaudio/cam1/sub1_4bn.txt +data/base/sequenceaudio/cam1/sub1_5pl.txt +data/base/sequenceaudio/cam1/sub17fmv.txt +data/base/sequenceaudio/cam2/c002.txa +data/base/sequenceaudio/cam2/c2diif2.txt +data/base/sequenceaudio/cam2/cam22fmv.txt +data/base/sequenceaudio/cam2/cam2_2n2.txt +data/base/sequenceaudio/cam2/cam2_2n.txt +data/base/sequenceaudio/cam2/cam22pl2.txt +data/base/sequenceaudio/cam2/cam22pl3.txt +data/base/sequenceaudio/cam2/cam26afm.txt +data/base/sequenceaudio/cam2/cam26bfm.txt +data/base/sequenceaudio/cam2/cam26pl1.txt +data/base/sequenceaudio/cam2/cam27fmv.txt +data/base/sequenceaudio/cam2/cam2acol.txt +data/base/sequenceaudio/cam2/cam2bcol.txt +data/base/sequenceaudio/cam2/cam2dico.txt +data/base/sequenceaudio/cam2/cam2diin.txt +data/base/sequenceaudio/cam2/cam2dipl.txt +data/base/sequenceaudio/cam3/c003.txa +data/base/sequenceaudio/cam3/c003.txt +data/base/sequenceaudio/cam3/c3ad2n2.txt +data/base/sequenceaudio/cam3/c3ad2pl3.txt +data/base/sequenceaudio/cam3/cam3_1bn.txt +data/base/sequenceaudio/cam3/cam32a2.txt +data/base/sequenceaudio/cam3/cam32alp.txt +data/base/sequenceaudio/cam3/cam32pl2.txt +data/base/sequenceaudio/cam3/cam34mu1.txt +data/base/sequenceaudio/cam3/cam34mu2.txt +data/base/sequenceaudio/cam3/cam3abf.txt +data/base/sequenceaudio/cam3/cam3abpl.txt +data/base/sequenceaudio/cam3/cam3ad2n.txt +data/base/sequenceaudio/cam3/cam3bg.txt +data/base/sequenceaudio/cam3/cam3_bn.txt +data/base/sequenceaudio/cam3/cam3_cn.txt +data/base/sequenceaudio/devastation.txa +data/base/sequenceaudio/devastation.txt +data/base/sequenceaudio/outro.txt data/mods/multiplay/dydo-ai/messages/strings/names.txt data/mods/multiplay/dydo-ai/multiplay/skirmish/ai.slo data/mods/multiplay/ntw/messages/strings/genstrings.txt diff --git a/po/update-po.sh b/po/update-po.sh index 267f24638..afd3f0b39 100755 --- a/po/update-po.sh +++ b/po/update-po.sh @@ -10,6 +10,6 @@ EOF find lib src data -type f | grep -v '\/.svn\/' | - grep -e '\.c\(pp\|xx\)\?$' -e 'data.*strings.*\.txt$' -e '\.slo$' -e '\.rmsg$' | + grep -e '\.c\(pp\|xx\)\?$' -e 'data.*strings.*\.txt$' -e 'data.*sequenceaudio.*\.tx.$' -e '\.slo$' -e '\.rmsg$' | grep -v -e '\.lex\.c\(pp\|xx\)\?$' -e '\.tab\.c\(pp\|xx\)\?$' -e 'lib/netplay/miniupnpc/*' -e 'GLee\.c' | sort >> po/POTFILES.in diff --git a/src/seqdisp.c b/src/seqdisp.c index ff861e745..045ea2e6a 100644 --- a/src/seqdisp.c +++ b/src/seqdisp.c @@ -625,7 +625,7 @@ static BOOL seq_AddTextFromFile(const char *pTextName, SEQ_TEXT_POSITIONING text ASSERT(pText != NULL, "error parsing text file"); if (pText != NULL) { - seq_AddTextForVideo(&pText[1], xOffset, yOffset, startFrame, endFrame, textJustification); + seq_AddTextForVideo(_(&pText[1]), xOffset, yOffset, startFrame, endFrame, textJustification); } } }