[Zope3-dev] Re: MessageID's automatic translation in TAL
Dmitry Vasiliev
lists at hlabs.spb.ru
Sun May 8 06:41:53 EDT 2005
Philipp von Weitershausen wrote:
> Godefroid Chapelle wrote:
>
>>> Jim, some other people and I argued that this kind of automation is
>>> bad anyway and instead of introducing more translation magic, TAL
>>> shouldn't do any automatic translation at all.
>>>
>>> So, in my opinion, do_insertText_tal() should raise a
>>> DeprecationWarning if it encounters a MessageID/Message object that
>>> doesn't have an accompanying i18n:translate declaration.
>>>
>>>> Stephan also have pointed that automatic translation doesn't allow
>>>> somebody to disable translation on purpose for some piece of content.
>>>
>>>
>>> Right. That's one reason why it's bad.
>>
>>
>> Can someone explain this use case a bit deeper ?
>
> Suppose you don't want to translate messages in a particular template
> that you want to have translated in others (for example editing vs.
> displaying a piece of translatable content). Or, suppose you want a
> particular message id translated in a different language than another
> one... Or, suppose you're building an app that manages message ids...
But now you just can define another method for the view which does something
like "return unicode(msgid)".
--
Dmitry Vasiliev (dima at hlabs.spb.ru)
http://hlabs.spb.ru
More information about the Zope3-dev
mailing list