嵌套注释和图形的问题

嵌套注释和图形的问题

现在这个问题可能太过局部化了,但我没有看到其他地方可以提供帮助。我有大量重要文件,在从 MikTex 切换到 TexLive 后,这些文件停止了编译(我重新安装了 Windows),经过一番摆弄后,我发现一些图形停止了编译

\documentclass[10pt]{article}
\usepackage{tikz,tkz-euclide}
\usepackage{comment}
\usepackage{kantlipsum}
\includecomment{foo}
\includecomment{fuu}
\includecomment{figurer}
\begin{document}
\begin{foo}
\kant[1]
\begin{fuu}
\kant[3]
\begin{figurer}
\begin{figure}[!htbp] \centering
\begin{tikzpicture}
  \tikzset{venn circle/.style={draw,circle,minimum width=6cm,fill=#1,opacity=0.4}}
\begin{scope}
  \node (D) at (2,4) {$\overline{\,F\,}\cap\overline{\,J\,}=2$}; 
\end{scope}
    \node (C) at (2,0) {};
      \tkzDrawCircle[R,fill=gray,opacity=0.4](C,5.25cm)
  \node [venn circle = red] (A) at (0,0) {};
  \node [venn circle = blue] (B) at (0:4cm) {};
  \node at (barycentric cs:A=1/2,B=1/2) {$F\cap J=10$};   
  \node  at (0,0) {$J=16$};
  \node  at (0:4cm) {$F=8$};
\end{tikzpicture}  
\end{figure}
\end{figurer}
\kant[4]
\end{fuu}
\end{foo}
\end{document}

这是一个稍微简单的例子,如果将 tikzpicture 改为一些更简单的东西,比如一条线,那么文件就可以很好地编译。

现在,我的问题是如何让嵌套评论和 tikzpicture 环境成为所有类型的图表和图表的朋友?

答案1

经过一番挖掘,我们发现这个问题与 TikZ 无关,ETC。,而是与文件读写的工作方式有关。在 Windows 上使用 TeX Live 时,使用演示文件时也会遇到同样的问题

\documentclass{article}
\usepackage{comment}
\includecomment{foo}
\includecomment{fuu}
\includecomment{figurer}
\begin{document}
\begingroup
\tracingall
\begin{foo}
\begin{fuu}
\begin{figurer}
A%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
B%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
C%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
D%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
E%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
F%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
G%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
H%%%%%
\end{figurer}
\end{fuu}
\end{foo}
\endgroup
\end{document}

导致问题的原因在于字符数,而不是内容(因此%显示了问题)。

我在 TeX Live 邮件列表中报告了这个问题,问题出在 TeX Live\input在 Windows 上的编码方式上。实际编译 W32 二进制文件的 Akira Kakuto 说

已确认。如果需要且允许,我可以用修复的二进制文件更新 TL2012 W32 二进制文件。(pdftex、tex、aleph 和 luatex)。在 W32 中,输入线()与跳过字节顺序标记略有不同。通过消除差异,错误就会消失。

TeX Live 应该有一个更新来解决这个问题。

相关内容