[Tex/LaTex] TeXworks + pdflatex + PSTricks autopp suffix problem

compilingpdftexpstrickstexworks

I have managed to make PSTricks work with TeXworks. However after compilation it adds -autopp to the basename of the pdf file, e.g. report.pdf becomes report-autopp.pdf. As a result TeXworks is not able to preview the file in a window.

How can I make TeXworks preview the pdf file? Am I doing something wrong? Here is my tex file:

\documentclass{article}
\usepackage[pdf]{pstricks}
\begin{document}
\begin{figure}
\begin{pspicture}(4,5)
\psframe(0.7,2)(3.3,3)
\rput(2,2.5){First Example}
\end{pspicture}
\end{figure}
\end{document}

Best Answer

use

\usepackage{pstricks}
\usepackage{auto-pst-pdf}

I'll have a look at the pstricks.sty why it didn't work under Windows. With Linux it is no problem. However, you have to run it with

pdflatex --shell-escape <file>

for TeXnicCenter and others see http://tug.org/PSTricks/main.cgi?file=pdf/pdfoutput#TXC