On Sun, Dec 14, 2014 at 6:45 PM, context context wrote:
> Could someone tell me how to install and use PSTricks in Context
First of all try to figure out if you could use MetaPost or TikZ
instead. Either of them is a lot more "pdf-friendly".
Unless you still work with MkII and go via dvi->ps->pdf, you need to
compile the PSTricks graphic separately into DVI, then PS, then PDF,
and include the final graphic into the document. While ConTeXt macros
can do that for you, it's still very ugly. Unless you have a very very
very strong reason to use PSTricks, you would be better off with other
solutions.
In any case PSTricks isn't supported in the standalone distribution,
so you need to use TeX Live.
This is (probably) the proper syntax to get it running:
\usemodule[pstricks]
\starttext
\startPSTRICKS
\psline(0,0)(3,3)
\stopPSTRICKS
\stoptext
But for MkII you need to enable unrestricted write18, else you end up with
runsystem(texexec test-texapp.tex --once --batch)...disabled (restricted).
runsystem(dvips test-texapp)...disabled (restricted).
runsystem(ps2pdf test-texapp.ps test-texapp.pdf)...disabled (restricted).
(and maybe then it won't work anyway) and for MkIV it currently fails
to work as well:
(/usr/local/texlive/2014/texmf-dist/tex/generic/pst-tools/pst-tools.tex
`PST-tools' v0.05, 2014/05/12 (hv)) v1.63, 2014/06/24 (tvz,hv))
pstricks : loading colors from colo-rgb
! I can't find file `colo-rgb'.
\loadpstrickscolors ...g colors from #1}\input #1
\relax \popmacro \dodefine...
l.47 ...s}{using indirect method; enable write18}}
(Press Enter to retry, or Control-D to exit)
Mojca
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the
Wiki!
maillist : [email protected] / 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
___________________________________________________________________________________