使用 easylist 进行词汇表描述

使用 easylist 进行词汇表描述

我试图easylist在条目描述中使用glossaries。但是,列表easylist没有格式化。有人知道如何让它工作吗?我试过使用\Activate\Deactivate命令,但没有帮助。

\documentclass{article}

\usepackage[xindy]{glossaries}
\usepackage[at]{easylist}

\setglossarystyle{treegroup}

\newcommand{\bel}{\begin{easylist}[enumerate]}
\newcommand{\eel}{\end{easylist}}

\setglossarystyle{treegroup}

\longnewglossaryentry{entry:enum}{
    name={enumerated entry},
}{% description
This is how I want the entries to look, but I want to use \texttt{easylist} instead of \texttt{enumerate}.
\begin{enumerate}
    \item
        stuff 1
    \item
        stuff 2
    \item
        stuff 3
\end{enumerate}
}

\longnewglossaryentry{entry:easy}{
    name={easylist entry},
}{% description
This entry should look like \gls{entry:enum}.
\bel
@ stuff 1
@ stuff 2
@ stuff 3
\eel
}

\begin{document}

This is my \gls{entry:enum}. This is an \gls{entry:easy}

\printglossaries

\end{document}

答案1

\Activate在序言中是有效的。

\documentclass{article}


\usepackage[at]{easylist}
\usepackage{glossaries}


\newcommand{\bel}{\begin{easylist}[enumerate]}
\newcommand{\eel}{\end{easylist}}

\setglossarystyle{treegroup}

\Activate
\makeglossaries


\longnewglossaryentry{entry:enum}{
    name={enumerated entry},
}{% description
  This is how I want the entries to look, but I want to use \texttt{easylist} instead of \texttt{enumerate}.
  \begin{enumerate}
  \item
    stuff 1
  \item
    stuff 2
  \item
    stuff 3
\end{enumerate}
}

\longnewglossaryentry{entry:easy}{%
  name={easylist entry}
}{%
  This entry should look like \gls{entry:enum}.
  \begin{easylist}[enumerate]
    @ stuff 1
    @ stuff 2
    @ stuff 3
  \end{easylist}
}

\Deactivate

\begin{document}

This is my \gls{entry:enum}. This is an \gls{entry:easy}

\printglossaries

\end{document}

在此处输入图片描述

相关内容