为什么 PStricks 只能使用 XeLaTeX 引擎进行编译,而不能使用 PDFLaTeX 进行编译。
当我使用 PDFLaTeX 进行编译时,出现错误 PDFLaTeX 无法找到包 pstricks。
答案1
使用以下文件运行
pdflatex --shell-escape <filename>
您将获得一个 pdf 输出。
\documentclass{article}
\usepackage{pst-eucl}
\usepackage[pspdf=-dNOSAFER]{auto-pst-pdf}
\begin{document}
\psset{unit=0.75}
\begin{pspicture}[showgrid](-5,-5)(13,10)
\pstTriangle[fillstyle=solid,fillcolor=red!60,opacity=0.3](0,0){A}(6,0){B}(2,4){C}
\pstCircleABC[PosAngle=60]{A}{B}{C}{O}
\pstBissectBAC[linestyle=none]{B}{A}{C}{A'}
\pcline[linestyle=dotted,nodesepB=-5cm](A)(A')
\pcline[linestyle=dashed,nodesepB=-5cm](A)(B)
\pcline[linestyle=dashed,nodesepB=-5cm](A)(C)
\pstOutBissectBAC[PointSymbol=none,PointName=none,linestyle=none]{C}{B}{A}{CBA}
\pstOutBissectBAC[PointSymbol=none,PointName=none,linestyle=none]{A}{C}{B}{ACB}
\pstInterLL{B}{CBA}{C}{ACB}{M1}
\pstProjection[PointName=I_1]{A}{B}{M1}[Mab]
\pstCircleOA[linecolor=red!60]{M1}{Mab}
\pstCircleOA[linecolor=red!60,linestyle=dashed,Radius=\pstDistAB{M1}{Mab}]{A}{}
\pstInterCC[Radius=\pstDistAB{M1}{Mab}]{A}{}{M1}{}{P1}{P2}
\psdots(P1)(P2)
\pstBissectBAC[linestyle=none]{A}{B}{C}{B'}
\pstInterLL[PointName=none]{A}{A'}{B}{B'}{Mi}
\psRelNode[angle=90](Mi)(A'){1}{ABi}\psdot(ABi)
\pcline[linestyle=dotted,nodesepB=-3cm](ABi)(Mi)
\pstInterLL[PointName=none]{A}{B}{Mi}{ABi}{E}\psdot(E)
\pstProjection[PointName=none]{A}{B}{Mi}[D]\psdot(D)
\psRelNode[angle=90](E)(B){2}{E'}\psdot(E')
\pstInterLL[PointName=none]{A}{A'}{E}{E'}{X}\psdot(X)
\pstCircleOA[linecolor=blue,linewidth=1.5pt,
fillstyle=solid,fillcolor=blue!50,opacity=0.3]{X}{E}
\pcline[linestyle=dotted](Mi)(D)
\pcline[linestyle=dotted](X)(E)
\end{pspicture}
\end{document}