1

I'm having issues trying to compile code that use the package "pstricks". When I compile the next code (which can be found here) with Xelatex:

\documentclass[pstricks,crop]{standalone}
\usepackage{pst-optic}
\usepackage{pstricks-add,pst-text}

\begin{document}

\begin{pspicture}(-8.5,-3)(8.5,3)
\rput(0,0){\lens[focus=3.333,OA=-10,AB=2,XO=2,xLeft=-8.5,xRight=8.5,rayColor=red]}
\end{pspicture}

\end{document}

I should have got the next output: desired_output

but instead, I always get the next one: actual_output

Then, when I try to compile other codes that also need the use of the package "pstricks" using Dvi -> PS and after that PS-> PDF I got warnings from Texmaker saying that:

MikTex GPL Ghostscript

9.19: ****Could not open the file output.pdf

That's why I downloaded ghostscript 9.23 and changed the Texmaker configuration:

enter image description here

but it doesn't work either. What should I do? Do I have to download a new DVI viewer?

In case it's needed, I use Texmaker 4.5 on Windows 7. Thank you very much!

  • 2
    I have no problem here with up-to-date TL2018 and xelatex. Try to use an external editor and not the Built-in Viewer of TeXMaker. This can be changed in the lower right of your config image. – user2478 May 27 '18 at 19:54
  • For an external viewer do not use the adobe reader, install Sumatrapdf, it is much more faster, – user2478 May 27 '18 at 20:00
  • Thank you Herbert. I tried as you said but the problem is still there. – Sergio RF May 28 '18 at 9:08
  • can you show the log file? – user2478 May 28 '18 at 10:21
  • Sorry for not answering before. I was sick of it. I think I'm gonna try with Tikz drawing everything by myself. Thank you anyway Herbert! – Sergio RF Jul 20 '18 at 8:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.