[Zope3-dev] i18n feature question/proposal

Sven Schomaker Sven.Schomaker at linie-m.de
Thu Apr 7 05:56:58 EDT 2005


Hello all,

I've recently been working on i18n of content fractions
by means of extended fields that require the content
component to provide a mapping to store locale dependent
content.

Currently I'm not quite certain about, whether this
is a neat style for the issue of fractional content
internationalization (internationalization just of
parts of the content-object and not the whole one
as content internationalization has been acchieved
by several z2 products, AFAIK) to be solved. This
is what I've got so far (it actually works great):

1 Fields need to be bound to the current locale,
  retrieved from the view/request. Whereas this
  makes it necessary to introduce some minor
  modifications to the form machinery, namely
  setUpDisplayWidgets, setUpEditWidgets, setUpWidget
  and probably _createWidget, to pass the locale to
  the field at the time it gets bound to the context,
  it does not require any modifications to the current
  widget set, since all locale specific logic will be
  realized by the fields.

2 This introduces several new field interfaces,
  (and its respective implementation) such as IText,
  ITextLine (and whatever is needed to store locale
  dependend content), that are derived from their
  non-internationalized counterparts. This would
  easily enable people to provide their content
  with internationalized text, etc. and also enable
  the z3 core to provide internationlized DC-titles
  and descriptions, for instance.

Hmm, maybe there is already another way to get fractional
content internationalization, that I missed? (Such as a
pretty nifty z3 package I just overlooked)

What is your opinion on this? Is there any interest on
making such thing part of z3, or would it have to vegetate
in a z3 branch hosted at my workplace, for the rest of its
life?

Regards,

Sven Schomaker


More information about the Zope3-dev mailing list