On Fri, 5 Jan 2007, cormullion@mac.com wrote:
On 2007-01-04, at 23:10.0, Aditya Mahajan wrote:
Perhaps the R module is easiest to understand. That method will work for most cases where you simply want to capture part of tex source and write it verbatim to a file, and then read the output back into tex.
I'm really grateful for your continuing help. Thanks - and I've got this working fairly easily. I'm trying to work out what ConTeXt does when it reads in the text that the external program writes to the tmp.out file...
basically \input reads a file and treats the material as if it were written in the tex file.
It might be that I have to output some TeX commands to the tmp.out file rather than just plain text.
That is what we do in t-vim module. The 2context.vim script writes a file that tex can understand.
That will require one of the other methods, i think.
Another option is \typefile{tmp.out} which will display the file verbatim, or \typevimfile[syntax=txt]{tmp.out} using txt.vim from http://www.vim.org/scripts/script.php?script_id=1532 Aditya