From 0c9cd5ea50982344b407ad5c4519c964c03f6a1d Mon Sep 17 00:00:00 2001 From: wl Date: Tue, 7 Feb 2006 06:10:39 +0000 Subject: * tmac/LOCALIZATION: New file. * man/groff_tmac.man: Mention fr.tmac. --- tmac/LOCALIZATION | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 tmac/LOCALIZATION (limited to 'tmac/LOCALIZATION') diff --git a/tmac/LOCALIZATION b/tmac/LOCALIZATION new file mode 100644 index 00000000..71f8c7cd --- /dev/null +++ b/tmac/LOCALIZATION @@ -0,0 +1,54 @@ + +Localization +------------ + +The localization process involves two files. + + - A locale dependent file (for example, fr.tmac for French) where all + locale specific strings are (re)defined. + + - A locale independent file (trans.tmac) responsible for activating those + localized strings. + +All you have to do is to create a new file named `LL.tmac' where `LL' is +your country code (`de' for Germany, `el' for Greece, ...), maybe using +`fr.tmac' as a template. + +The first thing to do is to redefine the string `locale' to your language. + + .ds locale german\" + +Then change all the translations in the predefined strings. Don't forget +the \" at the end of each string, preventing spaces from lurking around. + +After `trans.tmac' has been called by + + .mso trans.tmac + +you must redefine the date strings in order to use the day and month names +translated earlier. If you don't feel comfortable with groff maybe you +should use the definitions used in `fr.tmac'. Nevertheless, you should take +care of the order of the date elements. + + - If your date format is MM/DD/YY: + + for ms: .ds DY \*[MO] \n[dy] \n[year] + for mm: .ds cov*new-date \\*[MO\\n[mo]] \\n[dy] \\n[year] + for me: .ds td \*(mo \n(dy \n(y4 + + - If your date format is DD/MM/YY: + + for ms: .ds DY \n[dy] \*[MO] \n[year] + for mm: .ds cov*new-date \\n[dy] \\*[MO\\n[mo]] \\n[year] + for me: .ds td \n(dy \*(mo \n(y4 + +Other date formats can be handled similarly. + +NOTE: For the mm package, in the `ISODATE' macro, only the first definition + of `cov*new-date' must be changed (see `fr.tmac'). + +Finally, change groff behaviour in order to comply with your locale. For +example, `fr.tmac' changes the default encoding, sets the sentence spaces, +and final activates hyphenation, provided there are hyphenation patterns +available (which should be put into files named `hyphen.LL' for +consistency). -- cgit v1.2.1