[luatex] \input from Lua.

Paul Isambert zappathustra at free.fr
Mon Jan 31 13:19:38 CET 2011


Le 31/01/2011 11:31, luigi scarso a écrit :
> On Mon, Jan 31, 2011 at 11:29 AM, Paul Isambert<zappathustra at free.fr>  wrote:
>> Le 31/01/2011 10:35, Wolfgang Schuster a écrit :
>>> Am 29.01.2011 um 11:45 schrieb Paul Isambert:
>>>
>>>> Hello all,
>>>>
>>>> Is there a way to make TeX read a file from the Lua interface? The best I
>>>> can do is to issue:
>>>>
>>>> tex.print("\\input{" .. file .. "}")
>>>>
>>>> or something similar. But that is most inconvenient, and anyway it
>>>> doesn't work in an initialization script. (What I do in such a script is
>>>> register a function in "process_input_buffer" that returns the first line
>>>> prefixed with the desired \input statements, and then unregisters itself at
>>>> once. But that's horrible, it looks like a dirty trick!)
>>> With ConTeXt you write the above as “context.input("<file>")”.
>>>
>>> http://pragma-ade.com/general/manuals/cld-mkiv.pdf
>> Thanks, Wolfgang. Too bad I don't use ConTeXt :)
> perhaps  metatex ?
>
``I'm not a monster, I'm a plain TeX user,'' says John Merrick in a line 
deemed too obscure by the producers and replaced with ``I'm a human 
being'' behind David Lynch's back.


More information about the luatex mailing list