[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[RFC] improve i18n of webwml


here is a proposal to help translators's job:
   handle translated tags via PO files (i.e. gettext) instead of slices

It only applies to english/template/debian/*.wml files; other l10n-ed
tag definitions, as in ports/menu.defs, may follow this scheme later.
There is no need to change all files simultaneously since slice
machinery is always available.

In practice,
  <define-tag yes whitespace=delete>
is replaced by
  <define-tag yes whitespace=delete>

WML could then replace strings by looking into message catalogs, with
gettext bindings.  If string is not translated, English text is
returned, which is exactly what we want.

  * Languages are no more mixed in input files, so encoding issues
    should be solved
  * Translatable strings can be automatically extracted, thus
    translators do no more have to keep an eye on commits for templates
  * Translators cannot break templates (unless they forgot to close
    some tags in their translations)
  * Processed files are smaller, so build should run faster
  * When a string is updated by a translator, only a single language
    has to be rebuilt

  * Requires a not-yet released mp4h version.  It could have been done
    with pass 3 (eperl), but it would have been much trickier and more
  * Locales will surely give some surprise

If there is no objection, I will add a new directory
webwml/po/template/debian/ with the modified templates files, and the
PO files containing current translations.  This will be experimental,
in order to show how it works.  When it is ready,
webwml/english/template/debian/ is updated and webwml/po could be
entirely removed.


To UNSUBSCRIBE, email to debian-www-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

Reply to: