lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On Thu, Jul 25, 2013 at 10:19 AM, Marc Balmer <marc@msys.ch> wrote:
Any hints welcome!

Extracting strings from Lua sources is not difficult, especially with lpeg (or a simple Lua tokenizer such as in Penlight).

One just has to choose a convention, e.g double-quoted strings will be seen by users, single-quoted strings are internal.

But then, why not define a function such as L so that L"Hello World" will do the appropriate lookup?  First pass will return "Hello Word" but also create an entry in localization table(s).

Lua programs that I know of with internalization support are Sputnik and ZeroBrane studio, so perhaps Yury Y and Paul K can speak about that...