Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Including a postscript file into another one?

I wonder if there a standard way to include a postscript file into another. For example, say I have got one file of data generated by a 3rd party program:

%!PS
\mydata [ 1 2 3 4 5 6       
(...)
1098098
1098099
] def

and I would like to include it into a main PS document

%PS
\processData
{
mydata { (..) } foreach
}

(...)

(data.ps) include %<=== ???

Thanks

like image 731
Pierre Avatar asked Oct 26 '25 10:10

Pierre


1 Answers

The operator you want is run.

string   run   -       execute contents of named file

Unfortunately, run is not allowed if the interpreter has the SAFER option set.

Edit: Bill Casselman, author of *Mathematical Illustrations" has a Perl script called psinc you can use to "preprocess" yor postscript files, inlining all (...) run files.

like image 80
luser droog Avatar answered Oct 29 '25 08:10

luser droog