[pstricks] Using pstricks with Lua - is it possible?
lfsequeira at gmail.com
Wed Mar 7 17:23:32 CET 2012
I have used pstricks for years. One aspect that really interests me is the generation of complex pstricks figures programatically.
(for an example, consider generating a calendar for, a given year, say, 2013; it involves drawing 365 boxes, with numbers, different colors, markings for holidays, etc. and a lot of calculations that are better done in more general programming language, rather than LaTeX)
I have generated complex pstricks code like that, containing hundreds of commands, automatically (via C++ programming) - that involves writing a C++ program that writes down a tex file, and then running this through LaTeX
I was hoping to use Lua scripting to be able to automatically generate pstricks code, right from inside LaTeX, thus making this process self-contained.
But this looks like it may not be possible:
- running lualatex with pstricks code in the LaTeX file only appears to be possible through the auto-pst-pdf package;
- and that in turn spawns separate latex runs for all the pstricks stuff, where the lua scripting is *not* interpreted.
Is there some way to do this? Any suggestions? I am able to "script" regular LaTeX commands in lualatex, but I'm stumped because of the postscript nature of pstricks via the "pdflatex" nature of lualatex.
More information about the PSTricks