[Zope3-dev] Re: i18n domains vs. unique message ids -OR- why
Shakespearean English was better
Philipp von Weitershausen
philipp at weitershausen.de
Mon Aug 18 10:25:45 EDT 2003
Godefroid Chapelle wrote:
> Philipp von Weitershausen wrote:
>
>> We would therefore have to provide an English translation to Zope3 as
>> well, containg at least translation for these kinds of message ids.
>
> I think we cannot force english users to use the i18n machinery as most
> of them have not touched it ;-)
Someone who writes i18n-aware software need to use the i18n machinery. I
think we have good reason forcing Zope3 core developers to use it, even
if it only means import ZopeMessageIDFactory as _.
> Did you see the default argument to the constructor ;-) ?
I did, but guess what, the MessageIDFactory class doesn't support a
'default' argument in __call__, and ZopeMessageIDFactory is what we
currently use in Zope all over the place::
class MessageIDFactory:
"""Factory for creating MessageIDs."""
def __init__(self, domain):
self._domain = domain
def __call__(self, ustr):
return MessageID(ustr, domain=self._domain)
Now, it wouldn't be a struggle to add a 'default' argument to __call__,
but that was really not the point of my email. I know, for example, that
Stephan feels strongly about using different domains, so I wanted to
discuss this openly before it's too late and we're stuck with an
ambigious Zope3 UI.
Philipp
More information about the Zope3-dev
mailing list