From: Rudolf Polzer Date: Tue, 18 Jan 2011 20:06:18 +0000 (+0100) Subject: move i18n guide and badwords to .. X-Git-Tag: xonotic-v0.5.0~318^2~16 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=cddddefd29afa9f3f2cc380ed591ce9f8cadc7cf;p=xonotic%2Fxonotic-data.pk3dir.git move i18n guide and badwords to .. --- diff --git a/qcsrc/i18n-badwords.txt b/qcsrc/i18n-badwords.txt new file mode 100644 index 000000000..828fe0a8b --- /dev/null +++ b/qcsrc/i18n-badwords.txt @@ -0,0 +1,34 @@ +# list of words that must not be used in the source as a single string; +# use ZCTX(_("CONTEXT^string")) instead +# vi macro to do it: +# :s/_("\([^"]*\)")/ZCTX(_("CONTEXT^\1"))/g +# test by: +# grep -v ^# i18n-badwords.txt | while IFS= read -r W; do grep -nri "_(\"$W\")" menu/xonotic; done | sort -n +# this is done to help with languages like Russian where these words may need +# different grammatical gender in different instances +All +Best +Disabled +Good +High +Insane +Low +Lowest +Medium +Normal +Off +Ultra +Small +Large +Custom +Very short +Short +Long +Full +Empty +None +Few +Many +Lots +Both +Ambient: diff --git a/qcsrc/i18n-guide.txt b/qcsrc/i18n-guide.txt new file mode 100644 index 000000000..4e6d70cc5 --- /dev/null +++ b/qcsrc/i18n-guide.txt @@ -0,0 +1,59 @@ +How to make the .po template: + +find . -type f -not -name \*.po -not -name \*.txt | xgettext -LC -k_ -f- --from-code utf-8 + + +How to compare the .po template against a language file: + +msgcmp ../../menu.dat.de.po messages.po + + +How to merge the .po template into a language file: + +msgmerge -U ../../menu.dat.de.po messages.po + + +Guideline: +- do NOT translate strings in error() messages, or in dprint()! +- delete obviously useless developer prints while at it +- change obvious developer prints from print to dprint (even in comments), + unless in developer-only functions (e.g. *dumptree*) +- mark translatable strings with _() +- if a translatable string is a strcat monster, change it to sprintf +- if code loads files with text, use language_filename() +- interesting vim macros: + :map # /" + :map ' i_(2f"a)/" + +Unresolved TODO: + +- translated campaigns + +client/bgmscript.qc +client/casings.qc +client/ctf.qc +client/damage.qc +client/effects.qc +client/gibs.qc +client/hook.qc +client/hud.qc +client/hud.qh +client/laser.qc +client/Main.qc +client/main.qh +client/mapvoting.qc +client/miscfunctions.qc +client/modeleffects.qc +client/movetypes.qc +client/noise.qh +client/particles.qc +client/prandom.qc +client/projectile.qc +client/scoreboard.qc +client/target_music.qc +client/teamplay.qc +client/teamradar.qc +client/tuba.qc +client/View.qc +client/wall.qc +client/waypointsprites.qc diff --git a/qcsrc/menu/i18n-badwords.txt b/qcsrc/menu/i18n-badwords.txt deleted file mode 100644 index e3c4374c1..000000000 --- a/qcsrc/menu/i18n-badwords.txt +++ /dev/null @@ -1,34 +0,0 @@ -# list of words that must not be used in the source as a single string; -# use ZCTX(_("CONTEXT^string")) instead -# vi macro to do it: -# :s/_("\([^"]*\)")/ZCTX(_("CONTEXT^\1"))/g -# test by: -# grep -v ^# i18n-badwords.txt | while IFS= read -r W; do grep -nri "_(\"$W\")" xonotic; done | sort -n -# this is done to help with languages like Russian where these words may need -# different grammatical gender in different instances -All -Best -Disabled -Good -High -Insane -Low -Lowest -Medium -Normal -Off -Ultra -Small -Large -Custom -Very short -Short -Long -Full -Empty -None -Few -Many -Lots -Both -Ambient: diff --git a/qcsrc/menu/i18n-guide.txt b/qcsrc/menu/i18n-guide.txt deleted file mode 100644 index 95d662a56..000000000 --- a/qcsrc/menu/i18n-guide.txt +++ /dev/null @@ -1,30 +0,0 @@ -How to make the .po template: - -find . -type f -not -name \*.po -not -name \*.txt | xgettext -LC -k_ -f- --from-code utf-8 - - -How to compare the .po template against a language file: - -msgcmp ../../menu.dat.de.po messages.po - - -How to merge the .po template into a language file: - -msgmerge -U ../../menu.dat.de.po messages.po - - -Guideline: -- do NOT translate strings in error() messages, or in dprint()! -- delete obviously useless developer prints while at it -- change obvious developer prints from print to dprint (even in comments), - unless in developer-only functions (e.g. *dumptree*) -- mark translatable strings with _() -- if a translatable string is a strcat monster, change it to sprintf -- if code loads files with text, use language_filename() -- interesting vim macros: - :map # /" - :map ' i_(2f"a)/" - -Unresolved TODO: - -- translated campaigns