Rob Beezer
unread,Feb 5, 2018, 2:58:28 AM2/5/18Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to pretext...@googlegroups.com
Is anybody using PSTricks successfully via latex-image and
latex-image-preamble? I've had a request off-list to support such a thing, and
am moving the discussion here.
Edited transcript follows:
Rob -
> I strongly suspect you can use the PreTeXt "latex-image" and
> "latex-image-preamble" elements to incorporate PSTricks diagrams. I may give
> it a try later today in hopes of putting it into the documentation.
Alex -
> In PTX, the "latex-image" element (formerly "latex-image-code" if you see that
> in any discussions or documentation) is supposed to take /any/ relatively
> self-contained snippet of latex code. Almost, if not all examples up right now
> use a \begin{tikzpicture}...\end{tikzpicture} environment.
>
> In the book's docinfo, you need to have "latex-image-preamble". Again, right now
> pretty much all examples are using tikz, so this element has lines like
> \usepackage{tikz} or \usepackage{pgfplots}, plus some other tikz global settings.
>
> But I believe you could put all pstricks-related preamble stuff in the
> "latex-image-preamble", and then use "latex-image" elements with
> \begin{pspicture}...\end{pspicture} and all should work out well as long as the
> code doesn't need shell-escape or something like that.
>
> Note that you want to put pstricks preamble stuff in "latex-image-preamble", but
> not in any other PTX preamble insertion device, like say latex.preamble.late.
Alex -
> OK, remembered one thing. Once upon a time pstricks did not play with pdflatex.
> It only played with latex, dvips, etc. I stopped using it, and I have an inkling
> that now it works with pdflatex...maybe?
>
> But anyway, with PTX, you may want to stick with something that works with
> xelatex, and maybe Rob can tell you under what conditions pdflatex will be
> acceptable. Unsure about just plain old latex though. Hopefully that is not an
> impediment to using pstricks.
Rob -
Thanks, Alex, for both messages, which jibe well with my own recollections.
Almost never is xelatex a bad idea. Perhaps the default mbx.cfg file will
need to specify one or the other latex engine for success with PSTricks.