Emacs组织模式列表,TIKZ节点错误地导出到Xelatex Latex

时间:2012-10-23 21:28:53

标签: list export org-mode tikz xelatex

如果没有org-mode latex导出破坏环境,我如何在列表环境中包含Tikz节点?

我有一些代码,使用Tikz在几个列表项中创建大括号。理想情况下列表应该是这样的(这是我手动输入的xelatex代码......实际上我更喜欢“枚举”但一次只有一件事):

\begin{itemize}[noitemsep=nosep]
   \item who tells (to whom)?
     \tikz[remember picture] \node[coordinate,yshift=0.5em] (n1) {}; %max 2 sentences
   \item what happens?
   \item to whom?
   \item with what result?
     \tikz[remember picture] \node[coordinate] (n2) {};
     \tikz[remember picture] \node[coordinate, yshift=0.5em] (n3) {}; %max 4 sentences
   \item beginning
   \item how action rises
   \item climax
   \item denouncement
     \tikz[remember picture] \node[coordinate] (n4) {};
\end{itemize}

问题: Tikz代码列表中的中断导致列表环境中断,因此当我只需要一个列表时,我最终得到了多个列表。

请参阅下面的组织模式代码:

* My list starts here
 -  who tells (to whom)?
      #+BEGIN_LaTeX
      \tikz[remember picture]\node[coordinate,yshift=0.5em] (n1) {}; 
      #+END_LaTeX
 -  what happens?
 -  to whom?
 -  with what result?
     #+BEGIN_LaTeX
     \tikz[remember picture] \node[coordinate] (n2) {};\tikz[remember picture] \node[coordinate, yshift=0.5em] (n3) {}; 
     #+END_LaTeX
 -  beginning
 -  how action rises
 -  climax
 -  denouncement
     #+BEGIN_LaTeX
     \tikz[remember picture] \node[coordinate] (n4) {};
     #+END_LaTeX

请参见此处的Latex输出:

\begin{itemize}
\item who tells (to whom)?
\end{itemize} <--THIS IS THE PROBLEM, HOW CAN I STOP THE ITEMIZE ENVIRONMENT FROM ENDING HERE
\tikz[remember picture]\node[coordinate,yshift=0.5em] (n1) {}; 
\begin{itemize}
\item what happens?
\item to whom?
\item with what result?
\end{itemize}<--THIS IS THE PROBLEM AGAIN
\tikz[remember picture] \node[coordinate] (n2) {};\tikz[remember
picture] \node[coordinate, yshift=0.5em] (n3) {}; 
\begin{itemize}
\item beginning
\item how action rises
\item climax
\item denouncement
\end{itemize}<--THIS IS THE PROBLEM AGAIN, IT SHOULD BE THE ONLY \end{itemize} AND AT THE BOTTOM
\tikz[remember picture] \node[coordinate] (n4) {};

1 个答案:

答案 0 :(得分:1)

这个问题的答案是缩进列表中的tikz代码。在我意识到这是解决方案之后,我只是在本网站上的代码缩进后才意识到这一点。我正在测试新版本的org-mode,rvf0068建议,当我发现缩进是解决方案时。

-  who tells (to whom)?
   #+BEGIN_LaTeX
   \tikz[remember picture]\node[coordinate,yshift=0.5em] (n1) {}; 
   #+END_LaTeX
 -  what happens?
 -  to whom?
 -  with what result?

不会

-  who tells (to whom)?
#+BEGIN_LaTeX
\tikz[remember picture]\node[coordinate,yshift=0.5em] (n1) {}; 
#+END_LaTeX
 -  what happens?
 -  to whom?
 -  with what result?