[rkward-devel] i18n in rkwarddev?

meik michalke meik.michalke at uni-duesseldorf.de
Sun Feb 1 10:58:53 UTC 2015


hi,

Am Samstag, 31. Januar 2015, 20:30:03 schrieb Thomas Friedrichsmeier:
> what needs to be done in the result .js file is basically the following
> two replacements:
> 
>    echo ('rk.print("A translatable string")');
> -> echo ('rk.print(' + i18n ("A translatable string") + ')');
>    echo ('# a code comment\n');
> -> comment ('a code comment');
> 
> In rkwarddev, generation of the "echo()"-call is conveniently wrapped
> into an rkwarddev::echo(). The problem with this is, however,
> that we can't just make use of the js-function i18n() (and i18nc,
> i18np, i18ncp), here.

you are trying with the 0.06-5 release, right? have a look at the changelog 
for the upcoming release of 0.07-1; it had so many changed and new features 
that i felt the version jump more than justified.

amongst other things, there is
 - a re-write of i18n() which can be called inside echo() and covers all of 
   the i18n*() functions in one
 - a new function rk.i18n.comment() for context comments
 - a new argument "i18n" in a lot of XML functions which takes a list of 
   elements named "context" or "comment"
 - new default behaviour of rk.JS.header() to automatically use i18n
and various inclusions of i18n bits in other parts. and a lot of fixes...

this should already cover what you were wishing for. one thing i haven't 
implemented yet is the "internal"/"external" switch with different defaults 
for plugins.

let me know if i've missed some of the changes in RKWard 0.6.3.


viele grüße :: m.eik

-- 
  dipl. psych. meik michalke
  institut f"ur experimentelle psychologie
  abt. f"ur diagnostik und differentielle psychologie
  heinrich-heine-universit"at d-40204 d"usseldorf
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/rkward-devel/attachments/20150201/9b8e5767/attachment.sig>


More information about the rkward-devel mailing list