I have implemented a new way of using gettext from scheme files
that is easier to use than the string databases that are currently
used in, for example, the reports.

Essentially, it works the same way as in C.

To mark a string as translatable and load the translation
at the same time, use the '_' function:

(display (_ "Hello, World")) ;; print the appropriate translation
                             ;; of "Hello, World"

To makr a string as translatable without loading the translatable,
use the 'N_' function:

(define hello (N_ "Hello, World")) ;; mark "Hello, World" as
                                   ;; a translatable string
                                   ;; hello == "Hello, World"

(display (_ hello))                ;; print the appropriate
                                   ;; translation of "Hello, World"

The strings will be automatically collect statically during the
build process.

dave

_______________________________________________
gnucash-devel mailing list
[EMAIL PROTECTED]
http://www.gnumatic.com/cgi-bin/mailman/listinfo/gnucash-devel

Reply via email to