[Zope3-dev] i18n, unicode, and the underline

Fred L. Drake, Jr. fred@zope.com
Fri, 11 Apr 2003 09:42:03 -0400


Stephan Richter writes:
 > Barry is completely right with this! After a long discussion we decided to 
 > have all human interface strings as unicode. Also The _() is needed for 
 > translations; if Barry figures out how to do it without this, fine, if not 
 > they need to stay too.

I'm happy to keep the _() to mark strings for translation (in the case
of field definitions, marking is all you get to do; translation has to
happen when the information is presented).

Is there an objection to having the implementation of _() call
unicode(s, 'ascii') when the argument is an 8-bit string?  The result
is still Unicode for all intents and purposes, but there's less
decoration in the source; the _() is sufficient to mark the text as
translatable.

 > If Barry and I would have enough authority as I18n shepherds, I would veto 
 > this proposal (but I think Jim agrees with us, so he could make a Papal's 
 > Edict here too ;-). 

I can understand vetoing auto-converting the arguments to field
constructors.  Are you also vetoing having _() convert ASCII in 8-bit
strings to Unicode?  If so, I'd like to hear the rationale for that.

 > BTW, for each feature you pay a price of complexity and for I18n it is this, 
 > which is mild in my opinion. Star Office for example creates for each 
 > translatable string an array!

Yeah, but that's just insane.  And not Python.


  -Fred

-- 
Fred L. Drake, Jr.  <fred at zope.com>
PythonLabs at Zope Corporation