#10859: Make text not marked for translation stick out
-------------------------------------------+--------------------------------
 Reporter:  graham.carl...@maplecroft.com  |       Owner:  nobody    
   Status:  new                            |   Milestone:            
Component:  Internationalization           |     Version:  SVN       
 Keywords:                                 |       Stage:  Unreviewed
Has_patch:  0                              |  
-------------------------------------------+--------------------------------
 When changing templates to use the translation related tags, I found it
 quite tricky to chase down all the bits of text that needed translating.
 Finding *all* the text is especially important if the there will be a
 large turnaround time on the translations or there's a charge per set of
 translations.

 To be more confident I'd translated everything I hacked the django src to
 replace translatable text with the string "XXXX" so text that wasn't
 marked as translatable stood out.

 {{{
 Index: django/utils/translation/trans_real.py
 ===================================================================
 --- django/utils/translation/trans_real.py      (revision 10575)
 +++ django/utils/translation/trans_real.py      (working copy)
 @@ -83,6 +83,9 @@
      def __repr__(self):
          return "<DjangoTranslation lang:%s>" % self.__language

 +    def ugettext(self, msg_id):
 +        return u'XXXX'
 +
  class DjangoTranslation23(DjangoTranslation):
      """
      Compatibility class that is only used with Python 2.3.
 }}}

 So maybe this might be a useful "feature" to have. Possibly a setting to
 make the translation return a dummy value and maybe another setting for
 the value, being a string or a callable (taking the msg_id).

 {{{
 DEBUG_I18N = True
 DEBUG_I18N_TRANSLATOR = lambda(msg_id): "XXXX"
 }}}

 I suppose you could create a dummy po file to achieve a similar effect but
 I couldn't see any easy way of creating such a po file (that could be an
 alternative I suppose, a utility to generate such a file)

-- 
Ticket URL: <http://code.djangoproject.com/ticket/10859>
Django <http://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to