jgm / pandoc

Universal markup converter
https://pandoc.org
Other
34.91k stars 3.39k forks source link

Custom bulleted itemize env with Latex input and epub output #5386

Closed robinp closed 5 years ago

robinp commented 5 years ago

I have a custom itemize env in latex which overrides the bullet:

\newlist{mitigations}{itemize}{1}
\setlist[mitigations]{leftmargin=2em,label={\footnotesize{$\yinyang$}}}
\begin{mitigations}
\item foo
\end{mitigations}

But this doesn't even seem to have the bullets (let alone the specific one), when converting to epub.

Is there a suggestion here? First to accept this as a standard itemize env (with bullets), and maybe even to have the customized bullets. Thank you!

Edit: Actually, it's not a grave issue. I can use some output-dependent includes to switch the style used for epub.

jgm commented 5 years ago

We don't support \newlist (part of enumitem). Workaround: add this to the beginning of your latex document or preamble:

\newenvironment{mitigations}{\begin{itemize}}{\end{itemize}} 

This will cause the mitigations list to be parsed as a standard bullet list.

robinp commented 5 years ago

Thank you!