我使用定期更新的 2.9(完整安装)运行以下简单示例MikTeX
(这是 TikZ 手册中的第一个示例之一):
\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{arrows,calc,intersections}
\begin{document}
\begin{tikzpicture}
\path [name path=onek, draw] (2,0) -- (2,4);
\path [name path=twok, draw] (0,0) -- +(30:4);
\draw [name intersections={of=onek and twok, by=x}]
[very thick,red] (2,0) -- (x);
\end{tikzpicture}
\end{document}
并收到错误消息:
! Undefined control sequence.
<recently read> \pgfsetpath
l.44 ...me intersections={of=onek and twok, by=x}]
?
结果如下\listfile
:
*File List*
article.cls 2007/10/19 v1.4h Standard LaTeX document class
size10.clo 2007/10/19 v1.4h Standard LaTeX file (size option)
tikz.sty 2008/02/13 v2.00 (rcs-revision 1.27)
pgf.sty 2008/01/15 v2.00 (rcs-revision 1.12)
pgfrcs.sty 2008/02/20 v2.00 (rcs-revision 1.21)
pgfrcs.code.tex
pgfcore.sty 2008/01/15 v2.00 (rcs-revision 1.6)
graphicx.sty 1999/02/16 v1.0f Enhanced LaTeX Graphics (DPC,SPQR)
keyval.sty 1999/03/16 v1.13 key=value parser (DPC)
graphics.sty 2009/02/05 v1.0o Standard LaTeX Graphics (DPC,SPQR)
trig.sty 1999/03/16 v1.09 sin cos tan (DPC)
graphics.cfg 2007/01/18 v1.5 graphics configuration of teTeX/TeXLive
pdftex.def 2011/05/27 v0.06d Graphics/color for pdfTeX
infwarerr.sty 2010/04/08 v1.3 Providing info/warning/error messages (HO)
ltxcmds.sty 2011/11/09 v1.22 LaTeX kernel commands for general use (HO)
pgfsys.sty 2008/02/07 v2.00 (rcs-revision 1.31)
pgfsys.code.tex
pgfsyssoftpath.code.tex 2008/01/23 (rcs-revision 1.6)
pgfsysprotocol.code.tex 2006/10/16 (rcs-revision 1.4)
xcolor.sty 2007/01/21 v2.11 LaTeX color extensions (UK)
color.cfg 2007/01/18 v1.5 color configuration of teTeX/TeXLive
pgfcore.code.tex
pgfcomp-version-0-65.sty 2007/07/03 v2.00 (rcs-revision 1.7)
pgfcomp-version-1-18.sty 2007/07/23 v2.00 (rcs-revision 1.1)
pgffor.sty 2007/11/07 v2.00 (rcs-revision 1.8)
pgfkeys.sty
pgfkeys.code.tex
pgffor.code.tex
tikz.code.tex
supp-pdf.mkii
我猜我的一些 PGF 文件一定已经过时了,而且我很困惑为什么我使用 MikTeX 更新工具进行的频繁更新没有起作用。