[NTG-context] Problem with Lua processing UTF8 substrings

2012-02-01 Thread Jaroslav Hajtmar
Hello ConTeXist, I want to use Lua to write characters (substrings) from a string, but I get an error message: ! String contains an invalid utf-8 sequence. I tried various Lua functions for working with UTF8 strings for example: string.subutf8(string, start[,end]) for i, char in

Re: [NTG-context] Problem with Lua processing UTF8 substrings

2012-02-01 Thread Philipp Gesang
On 2012-02-01 20:26, Jaroslav Hajtmar wrote: I want to use Lua to write characters (substrings) from a string, but I get an error message: ! String contains an invalid utf-8 sequence. Can you please someone help? Have you tried the unicode library? The standard string library operates on

Re: [NTG-context] Problem with Lua processing UTF8 substrings

2012-02-01 Thread Jaroslav Hajtmar
Hello Philipp. Thanx very much for very quick and perfect help. Is there any manual or source, where I can read these (and next and similar) information? One more thanx Jaroslav Hajtmar Dne 1.2.2012 21:05, Philipp Gesang napsal(a): \def\mymacro#1{% \startluacode local utf =

Re: [NTG-context] Problem with Lua processing UTF8 substrings

2012-02-01 Thread Philipp Gesang
On 2012-02-01 21:17, Jaroslav Hajtmar wrote: Hello Philipp. Thanx very much for very quick and perfect help. Is there any manual or source, where I can read these (and next and similar) information? I’m sorry I have to disappoint you but the utf library is documented only in the source.[1]

Re: [NTG-context] Problem with Lua processing UTF8 substrings

2012-02-01 Thread Jaroslav Hajtmar
Thanx Philipp! It just - I do not mind studying the code ... Many thanx. Jaroslav Dne 1.2.2012 21:35, Philipp Gesang napsal(a): On 2012-02-01 21:17, Jaroslav Hajtmar wrote: Hello Philipp. Thanx very much for very quick and perfect help. Is there any manual or source, where I can read