Recently Stephan and me have a discussion on the IRC about purpose of i18n:translate attribute for tags with dynamic content through tal:content attribute. Stephan pointed out that i18n:translate in this case is just a marker for call translate() later. But later I discovered that TALInterpreter.do_isertText_tal() does the automatic translation for all MessageID's even when the t18n:translate isn't present.
So now the question: Do we need automatic translation for all MessageID's?
No, we don't need it. In fact, there has been a discussion on this a while ago in which Godefroid raised the issue that automatic translation of MessageIDs wasn't always happening. 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.
I'm personally think that automatic translation would be helpful in some cases.
Helpful in the sense of saving a few characters to type -- yes. In any other way it is more magic than sensible automation.
Philipp _______________________________________________ Zope3-dev mailing list Zope3firstname.lastname@example.org Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com