On Wed, 5 Feb 2014 15:37:21 -0500, Olemis Lang <[email protected]>
wrote :

> On Wed, Feb 5, 2014 at 2:43 PM, Saint Germain <[email protected]>
> wrote: [...]
> 
> > Nevermind : it was a setup problem (something with my browser
> > caching the .po file it seems).
> > So it works now. I'll update all the widget headers and update the
> > patch !
> >
> >
> 
> 
> oh well ! much better
> :)
> 

Ok it is fixed !

I have updated the ticket #694 with the patch against the current trunk
and also updated my bitbucket repository.

Almost everything is translated now but please check that what you have
previously detected is working now.

I also played a little with some strings which are not translated but
it is a challenge !

For instance consider the following code from
bhdashboard/widgets/templates/widget_product.html ("nobody" is currently
not extracted and so cannot be translated) :

<h4 i18n:msg="name,prefix,owner">
  &#9734; <a href="${p.href}">$p.name ($p.prefix)</a>
  <py:if test="p.owner_link">
    <br />
    <small>owned by
      <a href="$p.owner_link">${authorinfo(p._data['owner']) if 
p._data['owner'] else _('(nobody)')}</a>
    </small>
  </py:if>
</h4>

The best I can come up with is this :

<h4>
  &#9734; <i18n:msg params="name,prefix"><a href="${p.href}">$p.name 
($p.prefix)</a></i18n:msg>
  <py:if test="p.owner_link">
    <br />
    <small i18n:msg="owner">owned by
        <py:choose test="">
          <py:when test="p._data['owner']">
            <a href="$p.owner_link">${authorinfo(p._data['owner'])}</a>
          </py:when>
          <py:otherwise>
            <a href="$p.owner_link">(nobody)</a>
          </py:otherwise>
        </py:choose>
    </small>
  </py:if>
</h4>

But the extracted strings is quite ugly and non-understandable.

Perhaps somebody has a better idea ?

Regards,

Reply via email to