On Fri, Jul 25, 2003 at 09:17:16PM +0300, Tuomo Valkonen wrote:
> On Fri, Jul 25, 2003 at 07:03:42PM +0100, Keith Willoughby wrote:
> > It's better to have something like "Warning: file %s is obsolete" and
> > format it later (as like printf - I assume there's something similar
> > available in lua)
>
> string.format, and it's easy to define other functions with with printf
> style parameters as well:
>
> function translatef(str, ...)
> return string.format(translate(str), unpack(arg))
> end
>
> translatef("foo %s bar", "baz")
>
>
> or maybe warnf..
Ok, that might work. I can tell xgettext to look for functions of the
form translatef(str, foo, bar) and take the first parameter to be a translatable
string.
You don't mind me changing troublesome strings to be of this form, then?
--
Keith Willoughby http://flat222.org/keith/
Meet the new boss, just like the old boss
http://billmon.org/archives/000366.html