[Davical-dev] [DAViCal-general] Question about internationalization

Andrew McMillan andrew at morphoss.com
Fri Oct 23 21:26:18 NZDT 2009


On Thu, 2009-10-22 at 18:06 +0200, Matthias Mohr wrote:
> Hi Andrew,
> 
> Now I found out what was missing at my setup.
> My libawl directory is not reachable as "../awl" so the
> "rebuild-translations.sh" script was not able to detect the strings of
> the awl library.
> As a consequence all libawl-messages in my last contributed "de.po"
> have been commented out :-(

Thanks for spotting that.  I've added a test now that if it can't find
it in ../awl it looks in /usr/share/awl and if it can't see it there it
quits with a hopefully informative error message.


> Now I set a symbolic link to my real libawl directory and things go much better now...
> 
> Please find  a better and more complete version of my "de.po" as
> attachment to this mail.

Applied. Thanks.


> I still get strings which are not translated, but these are not as
> many as earlier...
> 
> What I still  get are the attempts to translate already translated
> strings and to translate my usernames...
> Which is a bit odd ;-)

There are some circumstances where the translations are somewhat blind
attempts to translate values that came out of the database, but I didn't
think it extended to usernames.  Relationship names, sure, but
usernames? That's odd.


> A short explanation about when to use the "i18n" method instead of
> "translate" and how the complete language cylce works would still 
> be really appreciated...

i18n() marks the string as something that is known that this string
needs to be able to be translated, but the actual place where the string
occurs is not where the translation occurs.  translate() actually does
the translation.  In fact i81n() is a runtime noop which is discovered
by extract.pl, so the string is included.

An example, is when you have many strings assigned in a case statement,
but only one of them is actually printed.  It is important that they all
be translated, but since only one will actually appear on the screen
it's silly to do the actual string conversion on all of them, so we use
i18n() inside the case statement where the assignment occurs, and
translate($variable) at the point where we print it.


> BTW, the URL to the Wiki-Translation page in the comments of the
> "i18n" method in "Translations.php" is wrong - it still contains 
> "RSCDS" instead of "DAViCal"...

Man, that name is hard to kill - in fact I can't find the place you
reference there... though I found some others :-)

Can you reference file/line?

Cheers,
					Andrew.

------------------------------------------------------------------------
andrew (AT) morphoss (DOT) com                            +64(272)DEBIAN
              You will feel hungry again in another hour.
------------------------------------------------------------------------

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part
URL: <http://lists.morphoss.com/pipermail/davical-dev/attachments/20091023/f4fafddb/attachment.pgp>


More information about the Davical-dev mailing list