#694: Translations scaffolding
------------------------+----------------------
  Reporter:  olemis     |      Owner:  olemis
      Type:  task       |     Status:  assigned
  Priority:  minor      |  Milestone:
 Component:  trac core  |    Version:  0.7.0
Resolution:             |   Keywords:  i18n
------------------------+----------------------

Comment (by olemis):

 Replying to [comment:70 SaintGermain]:
 > Replying to [comment:68 olemis]:
 [...]
 > >
 > > What about if a translation for ''Source'' is provided in the same
 catalog where ''Tickets'' is been translated ?
 > >
 >
 > I am not 100% sure but I think this is not the problem.
 >
 > In trac/web/chrome.py (see comment 64), label are retrieved and
 translated except if there is an overriding label in base.ini (for
 instance 'Tickets' and 'Source').
 > Bloodhound take the data as it is ('Ticket' and 'Source')

 IMO , these should be translated as well .
 @rjollos : what do you think ?

 > except for "Tickets" which got a special treatment (replace the href)
 which has a side result of translating 'Ticket' because we force the
 translation

 I see now .

 > If you want to have the same result for 'Source', we have also to
 duplicate that code for 'Source' (except that in our case we don't want to
 change the href, we just want to replace 'Source' by its translation).
 >

 We already have

 {{{#!sh

 $ grep -nr "RepositoryAdmin" bloodhound_theme
 bloodhound_theme/bhtheme/theme.py:512:
 href=req.href.wiki('TracRepositoryAdmin')))

 }}}

 This is the line that's replacing mainnav item when repository is not
 activated . The issue I mention actually happens when repository is not
 configured and that link is displayed , so ... my point is let's translate
 the caption as `Source` rather than `Browse Source` , this will create an
 entry in bhtheme translations catalog for that string and we could prepare
 other parts so as to ensure label will be translated . Notice that
 translations are applied if repos is connected / configured .

 [...]

-- 
Ticket URL: <https://issues.apache.org/bloodhound/ticket/694#comment:71>
Apache Bloodhound <https://issues.apache.org/bloodhound/>
The Apache Bloodhound issue tracker

Reply via email to