Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

below is a (long, non-working) minimal example for use of pdftricks with the memoir document class. It is based directly on the (shorter, working) minimal example of use of pdftricks found at http://www.tug.org/pipermail/macostex-archives/2009-June/040498.html. I get an error as follows:

! Undefined control sequence.
\psinputs ->\verbatimwrite 
                           {tmp.inputs}
l.28   \begin{psinputs}

Any help is appreciated!

\documentclass[article, a4paper, 12pt, twoside]{memoir}

\setlrmarginsandblock{23mm}{23mm}{*}
\setulmarginsandblock{23mm}{28mm}{*}
\setheadfoot{\onelineskip}{2\onelineskip}
\setheaderspaces{*}{1mm}{*}
\checkandfixthelayout
\setcounter{secnumdepth}{1}
\setsecindent{1cm}
\let\footruleskip\relax % for compatibility of memoir and fancyhdr
\let\sl\ttfamily        % for compatibility of memoir and blindtext (silly, but it works) ha ha \ttfamily
\let\sc\scshape
\let\bf\bfseries
\usepackage{fancyhdr}
\pagestyle{fancy}
\fancyhead{}
\fancyfoot{}
\cfoot{\thepage}
\renewcommand{\headrulewidth}{0pt}
%%% End of memoir stuff

\usepackage{ifpdf}
\ifpdf%
  \usepackage{pdftricks}
  \begin{psinputs}
    \usepackage{pstricks}
    \usepackage{pst-plot}
    \usepackage{pstricks-add} % <- added this line!
  \end{psinputs}
\else
  \usepackage{pstricks}
  \usepackage{pst-plot}
  \usepackage{pstricks-add} % <- added this line!
  \newenvironment{pdfpic}{}{}
\fi

\begin{document} 
\centering
\begin{pdfpic}
\begin{pspicture}(-1,-1)(6,6)
\psaxes[showOriginTick=false,showorigin=false,Dx=2,Dy=2,subticks=2](6,6)
\end{pspicture}
\end{pdfpic}
\end{document}
share|improve this question
    
Why do you want fancyhdr compatibility? Memoir can do all that stuff itself... –  Seamus Mar 21 '11 at 15:19

2 Answers 2

up vote 4 down vote accepted

Add \DisemulatePackage{moreverb} to the preamble, btw: you can reintroduce \sc using the oldfontcommands class option

share|improve this answer
    
thanks, worked for me. –  Joe Corneli Mar 21 '11 at 19:19

use the package auto-pst-pdfinstead of pdftricks. It really simplyfies the use of PSTricks:

...
\usepackage{auto-pst-pdf}
\usepackage{pstricks-add} % <- added this line!

\begin{document} 
\centering

\begin{pspicture}(-1,-1)(6,6)
\psaxes[showOriginTick=false,showorigin=false,Dx=2,Dy=2,subticks=2](6,6)
\end{pspicture}
...

run it as usual with pdflatex -shell-escape <file.tex>

share|improve this answer
    
nice suggestion, I'll try it when I get closer to final draft status. for the moment, installing auto-pst-pdf and all its dependencies is a bit heavy -- I'm using texlive 2007, no tlmgr :(. –  Joe Corneli Mar 21 '11 at 19:35
1  
ok, that is really old ... You can try to run pst2pdf. It is a Perl script, which extracts all PostScript specific part of your doc and creates single pdf images which then are used in a last pdflatex run. The script is available from CTAN. –  Herbert Mar 21 '11 at 19:45

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.