Changes between Version 132 and Version 133 of TracL10N
- Timestamp:
- Aug 3, 2018, 10:32:57 AM (6 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
TracL10N
v132 v133 1 1 [[PageOutline(2-4)]] 2 = Localization (L10N) of Trac = 2 3 = Localization (L10N) of Trac 3 4 4 5 Trac uses [pypi:Babel] for localization. Starting with version [milestone:0.12], Trac contains the i18n framework and L10N message catalog files. 5 6 6 From the user point of view, the ''Preferences / Language'' panel can be used to select the language from the list of available translations, otherwise the web browsers' language preferences will be honored, if possible. 7 8 If you're only interested in using a localized version of Trac, then nothing more than a standard TracInstall is needed, provided you installed Babel before. 9 10 The more complete installation instructions below are aimed at developers and translators, who want to contribute translations for Trac 0.12.x and beyond. 11 12 Note that this whole page is dedicated to the technical details of translating the Trac web application. There's also a parallel effort to translate the TracGuide, see TracGuideTranslations. While there's much more "text" to translate there, there are also much less technical constraints, so if you're intimidated by what follows but nevertheless would like to contribute back to Trac by providing your language expertise, here's a nice alternative! 13 14 == Installation == 15 16 === Getting the Tool Chain === 7 Trac users can select their localisation from the ''Preferences / Language'' panel. Otherwise the web browsers' language preferences will be honored, if possible. 8 9 If you are only interested in using a localized version of Trac, then only a standard TracInstall is needed, provided you installed Babel before. 10 11 The installation instructions below are aimed at developers and translators, who want to contribute translations for Trac 0.12.x and beyond. 12 13 This page describes the technical details of translating the Trac web application. There is also a parallel effort to translate the TracGuide, see TracGuideTranslations. It has much more "text" to translate, but there are also fewer technical constraints, so if you're intimidated by what follows but nevertheless would like to contribute back to Trac by providing your language expertise, here is a nice alternative! 14 15 == Installation 16 17 === Getting the Tool Chain 18 17 19 ==== Python Tools ==== #Pythontools 18 1. Install [http://babel.pocoo.org Babel] version [Babel:wiki:Download#LatestRelease:0.9.6 0.9.6] or newer [[br]] 19 Read the [http://babel.pocoo.org/en/latest/installation.html#living-on-the-edge detailed installation instructions] for Babel if you want to build it from source, but you should also be able to install it with a simple `easy_install` or by using one of the packages in the Download page linked above. 20 21 1. Install [http://babel.pocoo.org Babel] version [Babel:wiki:Download#LatestRelease:0.9.6 0.9.6] or newer. [[br]] 22 Read the [http://babel.pocoo.org/en/latest/installation.html#living-on-the-edge detailed installation instructions] for Babel if you want to build it from source. Alternatively you can install it with `easy_install` or by using one of the packages in the Download page linked above. 20 23 1. Likewise, install [https://genshi.edgewall.org/ Genshi] version [Genshi:wiki:Download#LatestRelease:0.7 0.7], 21 24 using `pip install` or by using one of the packages available for download. … … 26 29 - [source:branches/0.12-stable] for 0.12.x, \\ e.g. `svn checkout https://svn.edgewall.org/repos/trac/branches/0.12-stable trac-0.12.x` 27 30 28 All the discussion and examples below refer to `trunk`, but everything will work out exactly the same way for the `0.12-stable` branch or any other more recent branch. 29 30 === Translation Workflow === 31 32 It is very important to not waste time translating an out-of-date catalog. 33 34 In the repository, only the catalog **templates** ([source:trunk/trac/locale/messages.pot trac/locale/messages.pot] and [source:trunk/trac/locale/messages-js.pot trac/locale/messages-js.pot]) get updated regularly by Trac developers. If we would do so for the all the `.po` catalogs, this would generate lots of big and noisy changesets. So we leave that task up to the translators, which is something they should do before starting the actual translation work or before integrating updates coming from contributors when they're acting as translation team coordinators. 31 All the discussion and examples below refer to `trunk`, but everything works the same way for the `0.12-stable` branch or any other more recent branch. 32 33 === Translation Workflow 34 35 With new Trac versions being released, there is a real chance the catalog becomes out of date or is incomplete. In the repository, only the catalog **templates** ([source:trunk/trac/locale/messages.pot trac/locale/messages.pot] and [source:trunk/trac/locale/messages-js.pot trac/locale/messages-js.pot]) get updated regularly by Trac developers. If we would do so for the all the `.po` catalogs, this would generate big and noisy changesets. So we leave that task up to the translators, which is something they should do before starting the actual translation work or before integrating updates coming from contributors when they're acting as translation team coordinators. 35 36 36 37 There are several different procedures to get the catalogs in sync with the templates, choose the one you're more comfortable with. 37 38 38 ==== Using Python tools ====39 ==== Using Python tools 39 40 40 41 1. Run `python setup.py extract_messages`. [[br]] … … 42 43 source:trunk/trac/locale/messages.pot [[br]] 43 44 You should never have to edit that file manually. [[br]] 44 '''Note:''' ''this step is for committers only.''45 '''Note:''' this step is for committers only. 45 46 If you're not a Trac svn committer, you have to use the available 46 messages.pot, or bug us to update that file (though we do it on a47 regular basis ).47 messages.pot, or bug us to update that file, though we do it on a 48 regular basis. 48 49 1. Run `python setup.py update_catalog`. [[br]] 49 This will regenerate the variousstring catalogs50 This will regenerate the string catalogs 50 51 (`trac/locale/*/LC_MESSAGES/messages.po`), 51 52 preserving the previously translated strings and merging the new 52 53 translations found in the messages.pot file. Translations that are 53 54 no longer needed are commented out (`#~`) and moved at the bottom of the 54 .po file (be careful, they will be discar ed by the next update, so if55 .po file (be careful, they will be discarded by the next update, so if 55 56 they contain valuable content, save it somewhere). [[br]] 56 57 Usually, you will be interested in working on one locale only, so you … … 58 59 For example: [[br]] 59 60 `python setup.py update_catalog -l nl`. [[br]] 60 1. Now, open your favorite editor and add or modify translations for the61 1. Open your favorite editor and add or modify translations for the 61 62 extracted strings in the messages.po file for your language. 62 63 [[comment(See examples below.)]] 63 1. Once you're done, you should**validate** your translations:64 1. Run `python setup.py update_catalog -l` again , for normalizingthe64 1. Once you're done, **validate** your translations: 65 1. Run `python setup.py update_catalog -l` again to normalize the 65 66 manual edits. For example: [[br]] 66 67 `python setup.py update_catalog -l nl`. [[br]] 67 This step is also quite useful for spotting the possiblemistakes,68 This step is also useful for spotting mistakes, 68 69 like accidental changes of `msgid` strings. Look for lines beginning 69 70 with `#~`, they are indicative of such errors. Note that the comments 70 71 corresponding to translations which are no longer present in the 71 messages.pot file (as discussed in step 2 .above) have been discarded72 messages.pot file (as discussed in step 2 above) have been discarded 72 73 by this second `update_catalog` run. 73 2. Run `python setup.py check_catalog -f`. [[br]]74 1. Run `python setup.py check_catalog -f`. [[br]] 74 75 This will search the catalog for common mistakes, like placeholder 75 76 mismatches, invalid embedding in Genshi's structure messages, etc. 76 3. Run `python setup.py compile_catalog -f`. [[br]]77 1. Run `python setup.py compile_catalog -f`. [[br]] 77 78 This will generate one compiled catalog (`message.mo` file) for each 78 79 (or each specified) messages.po file. You don't need to do anything 79 80 with those files, they'll get installed automatically. [[br]] 80 You will most probably need to use the force option (`-f`) in orderto81 You will likely need to use the force option (`-f`) to 81 82 compile catalogs marked "fuzzy". It is fine to have ''fuzzy'' translations 82 but try to nevercontribute a translation still containing those markers,83 but try not to contribute a translation still containing those markers, 83 84 as they mean that a given translation has not been reviewed by a human 84 85 but were machine generated. Fuzzy translations should be either cleared 85 86 when they are wrong, or validated when they are correct, by removing the 86 ''fuzzy'' tag or even the whole line if f''fuzzy'' was the only keyword on87 that line [[br]]87 ''fuzzy'' tag or even the whole line if ''fuzzy'' was the only keyword on 88 that line. [[br]] 88 89 You can also use the `-l` option here to specify the locale for which 89 90 the messages.po has to be compiled. 90 3. Run `python setup.py install` for installing Trac and locale data.91 1. Run `python setup.py install` for installing Trac and locale data. 91 92 Alternatively you can use `python setup.py develop` once for all, 92 if you want to be able torun Trac from your working copy.93 if you want to run Trac from your working copy. 93 94 Beware that there's no ''on the fly'' compilation of the catalogs, 94 95 so any change will have to go through step 4.3 (compile) before being 95 96 visible in your Trac instance. 96 97 97 If you skip the 4th step (validation), you risk to submit incomplete or, 98 worse, buggy messages.po files. Going through the 4th step will ensure a 99 better quality standard. Finally, seeing your translations "live" in Trac is 100 not only a great way to realize if the translation still makes sense once put 101 in context, but also quite gratifying when you see that you picked the correct 102 wording ;-) 103 104 Note that the above was written at a time there was only //one// catalog file, 105 messages.pot. So in order to be complete, you'd have to repeat this for all 106 the catalogs: 98 If you skip the validation step, you risk submitting incomplete or buggy messages.po files, which reduces the user experience. Also, seeing your translations "live" in Trac is not only a great way to establish whether the translation still makes sense once put in context, but also quite gratifying when you see that you picked the correct wording. 99 100 Note that the above was written at a time there was only //one// catalog file, messages.pot. So to be complete, you would have to repeat this for all the catalogs: 107 101 - `messages-js` 108 102 - `extract_messages_js` … … 117 111 - `compile_catalog_tracini` 118 112 119 If this look tedious and you're thinking about scripting all of this... don't worry, that has already been done, see [#using-make] below. 120 121 ==== Using `msgfmt` tools ==== 122 123 Although Babel is Python specific and is the tool which is advised to use, 124 the traditional [http://linux.die.net/man/1/msgfmt msgfmt] toolset (part of GNU `gettext`) can also be used, but preferably for related tasks like checking the catalogs and getting statistics, rather than updating or the compiling the catalogs. 125 126 In particular, the following command is quite useful: 113 If this looks tedious and you're thinking about scripting all of this, don't worry, that has already been done, see [#using-make] below. 114 115 ==== Using `msgfmt` tools 116 117 Although Babel is Python specific and is the tool which is advised to use, the traditional [http://linux.die.net/man/1/msgfmt msgfmt] toolset (part of GNU `gettext`) can also be used. However, `msgfmt` is best used for auxiliary tasks like checking the catalogs and getting statistics, rather than updating or the compiling the catalogs: 118 127 119 {{{ 128 120 $ msgfmt --statistics --check trac/locale/pl/LC_MESSAGES/messages.po 129 121 884 translated messages, 166 fuzzy translations, 80 untranslated messages. 130 122 }}} 131 All is well, except for some fuzzy and missing translations ;-)123 All is well, except for some fuzzy and missing translations. 132 124 133 125 {{{ … … 141 133 Some errors were detected with format specifications. 142 134 143 This is a useful ''additional'' check, as neither `python setup.py compile_catalog -l zh_CN` nor `python setup.py check_catalog -l zh_CN` wouldn't have detected that issue. FIXME //we detect mismatches, but not missing placeholders in `msgstr`// 144 145 146 ==== Using Transifex ==== 147 148 The web-based collaborative site for translations Transifex has 149 a [Transifex: project page for Trac] and its convenient user interface makes it very attractive for translators who don't want to mess directly with the source code. 135 This is a useful ''additional'' check, as neither `python setup.py compile_catalog -l zh_CN` nor `python setup.py check_catalog -l zh_CN` would have detected that issue. FIXME //we detect mismatches, but not missing placeholders in `msgstr`// 136 137 ==== Using Transifex 138 139 The web-based collaborative site for translations Transifex has a [Transifex: project page for Trac] and its convenient user interface makes it attractive for translators who don't want to edit the source code directly. 150 140 151 141 There, a number of "resources" (`.pot` messages catalog files in our case) are grouped in several "releases". Currently the "releases" corresponds to our maintenance branches. … … 168 158 - [Transifex:resource/trunk-tracini-pot trunk - trac/locale/tracini.pot] 169 159 170 Once you're member of a translation team, you can add translations directly online. But in the end, the changes will have to be committed back to the source tree, so you better have to check beforehand with the translator coordinator of your language to see ifis comfortable with getting updates from Transifex.160 Once you're member of a translation team, you can add translations directly online. But in the end, the changes will have to be committed back to the source tree, so you have to check beforehand with the translator coordinator of your language to see if (s)he is comfortable with getting updates from Transifex. 171 161 172 162 If you are a translation team coordinator, **please refer to the [./Transifex] sub page** for more details. 173 163 174 175 164 ==== The easy way using `make` and l10n targets ==== #using-make 176 165 177 You'll find a Makefile in the toplevel directory of the Trac source. 178 If you're lucky enough to have the GNU `make` tool, you can benefit from some 179 automation for these translation tasks. 166 You'll find a Makefile in the toplevel directory of the Trac source. If you have the GNU `make` tool, you can benefit from some automation for these translation tasks. 180 167 181 168 {{{ … … 238 225 }}} 239 226 240 == Contributing ==241 242 The various catalog files (`messages.po`) can be found in the repository under source:trunk/trac/locale. The `messages.pot` is the template file from which the variouslocale-specific files get created.227 == Contributing 228 229 The catalog files (`messages.po`) can be found in the repository under source:trunk/trac/locale. The `messages.pot` is the template file from which the locale-specific files get created. 243 230 244 231 === Adding translations for a new language #add-a-language … … 248 235 $ ./setup.py init_catalog -l et 249 236 }}} 250 Use ISO:639-1 language codes, only use national variant when there's a real need. 251 252 We also added support for translating messages in Javascript code. 253 Those messages are collected in a separate catalog, so you need a separate command: 237 Use ISO:639-1 language codes, only use national variant when there is a real need. 238 239 We also added support for translating messages in Javascript code. Those messages are collected in a separate catalog, so you need a separate command: 254 240 {{{ 255 241 $ ./setup.py init_catalog_js -l et … … 258 244 Alternatively, you can do `make init-<locale>`, this will create the missing catalog(s) if needed. 259 245 260 261 246 Then proceed through the steps listed [#Pythontools above] starting at step 2. 262 247 263 264 248 === How far would you like to go? 265 249 266 Th e amount of translatable text could be seen as overwhelming... You don't have to translate **everything** though in orderto provide a good l10n experience to your users.267 268 I think we can distinguish 3 levels:269 1. user-oriented translations: those are all contained in the `messages.po` and `messages-js.po` catalogs; if you reach 100% there you're already a hero (Hello Itamar! ;-))270 2. administrator-oriented translations: since 1.0 we also introduced the possibility to translate the documentation information for the numerous TracIni settings, in the `tracini.po` catalog; for now those are primarilytargeted at Trac administrators, so translating those could really be seen as an "bonus" level271 3. TracGuideTranslations -- various people have attempted to translate the TracGuide, but this would reallybe a huge effort; maybe in the future we could isolate a smaller subset of user oriented pages of the TracGuide272 4. Translating the API documentation (and why not also the source code?). Hey, just kidding ;-)273 274 === Statistics ===250 Though the amount of translatable text can be overwhelming, you don't have to translate **everything** to provide a good l10n experience to your users. 251 252 We can distinguish 3 levels: 253 1. User-oriented translations: those are all contained in the `messages.po` and `messages-js.po` catalogs; if you reach 100% there you're already a hero (Hello Itamar!) 254 1. Administrator-oriented translations: since 1.0 we also introduced the possibility to translate the documentation information for the TracIni settings, in the `tracini.po` catalog; those are targeted at Trac administrators, so translating those could really be seen as an "bonus" level 255 1. TracGuideTranslations: there have already been attempts to translate the TracGuide, but this would be a huge effort; maybe in the future we could isolate a smaller subset of user oriented pages of the TracGuide 256 1. Translating the API documentation (and why not also the source code?). 257 258 === Statistics 275 259 276 260 Those statistics reflect the coverage status of the `.po` files (catalogs) compared to the `.pot` files (catalog templates). The template catalogs themselves **might** be out-of-date compared to the source itself, though we regularly perform an automatic extraction. … … 298 282 299 283 300 Note that if the statistics for a language suddenly drop to 0%, 301 this is indicative of the presence of ''fatal errors'' 302 (as reported by `msgfmt --check`) in the corresponding `messages.po` file. 303 304 If you want to generate those statistics by yourself, do `make summary`. 305 Be aware that those statistics can only be accurate if the catalogs are actually up to date with respect to the catalog template, so you should do a `make update` before. As this is quite expensive, you may want to do only `make update summary locale="..."` for the locales you're interested in. 306 307 === Editing Guidelines === 308 309 There are tons of good guidelines on the web about how to write good translations. 310 See for example: [http://techbase.kde.org/Localization/Concepts/PO_Odyssey PO_Odyssey] and [http://l10n.kde.org/docs/translation-howto/gui-step-by-step.html step-by-step], and other resources from http://l10n.kde.org. ''(The references also applies to translators using Windows, though the set of translation editors seems to be narrower. However, see [http://www.poedit.net/ Poedit] for a multiplatform dedicated PO editor.)'' 284 Note that if the statistics for a language suddenly drop to 0%, this is indicative of the presence of ''fatal errors'' (as reported by `msgfmt --check`) in the corresponding `messages.po` file. 285 286 If you want to generate those statistics yourself, do `make summary`. Those statistics are only accurate if the catalogs are actually up to date with respect to the catalog template, so do a `make update` beforehand. As this is computationally expensive, you may want to `make update summary locale="..."` for the locales you're interested in. 287 288 === Editing Guidelines 289 290 There are many good guidelines on the web about how to write good translations. See for example: [http://techbase.kde.org/Localization/Concepts/PO_Odyssey PO_Odyssey] and [http://l10n.kde.org/docs/translation-howto/gui-step-by-step.html step-by-step], and other resources from http://l10n.kde.org. The references also apply to translators using Windows, though the set of translation editors seems to be narrower. However, see [http://www.poedit.net/ Poedit] for a multi-platform dedicated PO editor. 311 291 312 292 In short, a translation unit is typically something like: … … 318 298 }}} 319 299 320 - the "#:" lines are comments indicating the locations of the message in 321 the source. 322 - `msgid "..."` is the message itself, this should never be changed 323 - `msgstr` is your translation; you should keep there the same structure, 324 as in the msgid. In particular the presence of "\n" at the beginning or 325 the end of the msgid should be mirrored in msgstr 300 - the "#:" lines are comments indicating the locations of the message in the source. 301 - `msgid "..."` is the message itself, this should never be changed. 302 - `msgstr` is your translation; you should keep there the same structure, as in the msgid. In particular the presence of "\n" at the beginning or the end of the msgid should be mirrored in msgstr. 326 303 - right after an automatic catalog update you'll see lots of: 327 - `# fuzzy` comments: this identifies translations that are only 328 approximated (the msgid has changed) 304 - `# fuzzy` comments: this identifies translations that are only approximated (the msgid has changed) 329 305 - `msgstr ""` translations: those are newly added translations 330 306 331 307 There are a few more complex situations. 332 308 333 Here 's a message containing parameters:309 Here is a message containing parameters: 334 310 {{{ 335 311 #: trac/ticket/templates/milestone_view.html:26 … … 343 319 }}} 344 320 345 Note that **you need to keep the same set of parameters in `msgid` 346 and `msgstr`, both for the name and the keyword** (i.e. don't 347 replace a `%(id)s` with a `%(id)d`), although you can reorder them as needed. 348 349 350 Another example, here's how a structured message looks like: 321 Note that **you need to keep the same set of parameters in `msgid` and `msgstr`, both for the name and the keyword**, ie don't replace a `%(id)s` with a `%(id)d`, although you can reorder them as needed. 322 323 Another example, here is how a structured message looks like: 351 324 {{{ 352 325 #: trac/ticket/templates/milestone_delete.html:45 … … 360 333 }}} 361 334 362 The `[1: ...]` groups are used when the message contains markup 363 (this is Genshi specific). 364 It is important to keep the same semantic structure. 365 As with message parameters, the groups can be reordered but **you should 366 have the same groups in `msgid` and `msgstr`** (see for example r9553). 367 The various `check_catalog_*` commands (`make check`) now look for such errors. 368 369 Of course, you can have messages that combine markup groups and 370 parameters names: 335 The `[1: ...]` groups are used when the message contains markup (this is Genshi specific). It is important to keep the same semantic structure. As with message parameters, the groups can be reordered but **you should have the same groups in `msgid` and `msgstr`** (see for example r9553). The `check_catalog_*` commands (`make check`) now look for such errors. 336 337 Of course, you can have messages that combine markup groups and parameter names: 371 338 {{{ 372 339 #: trac/ticket/templates/milestone_view.html:32 … … 380 347 }}} 381 348 382 383 Finally, there's the translation of sentences which have a singular and 384 a plural form: 349 Finally, there is the translation of sentences which have a singular and a plural form: 385 350 {{{ 386 351 #: trac/ticket/templates/query.html:29 … … 394 359 }}} 395 360 396 - when such a message is newly added, you'll have [[br]] 397 `#, fuzzy, python-format` as the first comment. 398 Be careful to remove only the `fuzzy, ` part, but not the `python-format` 399 keyword. 400 - some languages (zh, ko, ja) don't have plural forms (plural == 1), 401 so you only have to put a `msgstr[0]` line. 402 - some other languages have more than 2 plural forms, so you need as 403 many `msgstr[]` as needed. 404 405 361 - when such a message is newly added, you will have `#, fuzzy, python-format` as the first comment. 362 Be careful to remove only the `fuzzy, ` part, but not the `python-format` keyword. 363 - some languages (zh, ko, ja) don't have plural forms (plural == 1), so you only have to put a `msgstr[0]` line. 364 - some other languages have more than 2 plural forms, so you need as many `msgstr[]` as needed. 406 365 407 366 === Terms (Definitions) === #term-definitions 408 367 409 Consistent and careful translation of terms like [wiki:TracTimeline timeline], [wiki:TracTickets ticket], [wiki:TracReports report] is very important. These 410 terms are used everywhere and must be easy to remember and comfortable to use. 411 412 The way to make up good translations of important terms is to discuss them before using everywhere. The easiest way to accomplish it is to set up wiki pages for different languages. 413 414 Look also at the various term definition pages: [[TitleIndex(TracTerms,hideprefix,format=compact)]]. 368 Consistent and careful translation of terms like [wiki:TracTimeline timeline], [wiki:TracTickets ticket], [wiki:TracReports report] is very important. These terms are used everywhere and must be easy to remember and comfortable to use. 369 370 The way to make up good translations of important terms is to discuss them before using everywhere. The easiest way to accomplish this is to set up wiki pages for different languages. 371 372 Look also at the term definition pages: [[TitleIndex(TracTerms,hideprefix,format=compact)]]. 415 373 416 374 === Translation Coordination === #Translationcoordination 417 375 418 For the various languages there are already varioustickets logged in which the work on them is tracked:376 For the various languages there are already tickets logged in which the work on them is tracked: 419 377 [[TicketQuery(keywords~=l10n,status!=closed,order=summary)]] 420 378 421 379 This is a way by which translators for the same language can coordinate their work. 422 380 423 It is also important to subscribe to the Trac-dev MailingList, in order to be notified of the release schedule, of the "string freeze" periods shortly preceding a release. During a string freeze we don't add new messages or modify existing ones, so this is the ideal period for finalizing a translation. 424 381 It is also important to subscribe to the Trac-dev MailingList, to be notified of the release schedule, of the "string freeze" periods shortly preceding a release. During a string freeze we don't add new messages or modify existing ones, so this is the ideal period for finalizing a translation. 425 382 426 383 === For Committers 427 384 428 If you have commit access to the translation catalogs in the SubversionRepository, then you should be careful to commit only error-less updates. Translations can be fuzzy or missing, that's not a problem, but the errors spotted by `make check compile locale=<yourlocale>` should really be fixed before committing. Please also take care of fixing any `[n:...]` nesting serrors reported by `make check`, as those mistakes are quite deadly (#9171).385 If you have commit access to the translation catalogs in the SubversionRepository, then you should be careful to commit only error-less updates. Translations can be fuzzy or missing, that's not a problem, but the errors spotted by `make check compile locale=<yourlocale>` should really be fixed before committing. Please also take care of fixing any `[n:...]` nesting errors reported by `make check`, as those mistakes are quite deadly (#9171). 429 386 430 387 The commit message should have the following format: … … 469 426 [...] 470 427 }}} 471 At this point, one can inspect the remaining meaningful conflicts and resolve dthem manually.428 At this point, one can inspect the remaining meaningful conflicts and resolve them manually. 472 429 473 430 Then: … … 477 434 to remove the spurious line number difference, review and commit. 478 435 479 480 436 === For Developers 481 437 482 438 Here's a condensed list of a few things useful to know about i18n support when coding: 483 title attributes:: 484 those attributes are collected automatically (i.e. no need for explicit `${_('...')}` expressions), but only when the message doesn't contain an expression. In the latter case, they need an explicit `${_('... %(param)s ...', param=...)}` wrapping 439 title attributes:: those attributes are collected automatically, ie no need for explicit `${_('...')}` expressions, but only when the message doesn't contain an expression. In the latter case, they need an explicit `${_('... %(param)s ...', param=...)}` wrapping 485 440 typographical translation:: some languages, like French, have special typographical rules (non breaking space before ":" or ";"), so don't consider that those signs can be left outside of translation scope when part of the text (e.g. use `_(";")` when ";" is used as a separator, `_("%(field)s:")` instead of `'%(field)s:'`) 486 messages consolidation:: 487 when adding new messages, always look if there's not already a very close message, and then reuse it (e.g. we now have 7 //occurrences// of one single ''"Repository '%(repo)s' not found"'' message, previously we had 7 //messages//, each slightly different from the other!) 441 messages consolidation:: when adding new messages, always look if there is not already a very close message, and then reuse it (e.g. we now have 7 //occurrences// of one single ''"Repository '%(repo)s' not found"'' message, previously we had 7 //messages//, each slightly different from the other!) 488 442 non-translatable messages:: in Genshi templates, you can use `xml:lang="en"` to mark the text in the element as not to be extracted (r10265) 489 443 … … 491 445 492 446 === Open Issues === #Openissues 447 493 448 - ''' help us spot the MissingTranslations in the source code ''' 494 - some terms that should be translated are simply not present in the source code, but rather live in the TracIni or the database. .. but even for these nasty ones we have a plan: TracDev/Proposals/ConfigEnumTranslation449 - some terms that should be translated are simply not present in the source code, but rather live in the TracIni or the database. Even for these nasty ones we have a plan: TracDev/Proposals/ConfigEnumTranslation 495 450 - translation of wiki pages (#1513) and help pages (TracDev/Proposals/NewHelp) 496 451