I seek how to use context-lua to draw a path from ‘points’ in an external file.
Below is one way to plot points from an external file, call the file DATA with contents: 1 3 -2 2 -3 -1 3 -2 \starttext \startluacode local metafun = context.metafun metafun.start() io.input(“DATA") while true do local x, y = io.read("*n", "*n") if not x then break end metafun("filldraw fullcircle scaled 2mm shifted(%dcm,%dcm);",x,y) end metafun.stop() \stopluacode \stoptext How to make this a polygon? I know other ways to read and manipulate DATA with Lua—it is the drawing part where I most look for help. Thanks, John ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________