2

My main document is based on memoir documentclass. For inclusion of figures I use standalone package. It collaborate fine. But I have problem, how to include in figures (using standalone document class), that it can use some memoir specific formatting of document? Something like:

\docummentclass[12pt,tikz]{standalone}
\usepackage{????} %this should somehow incorporate memoir formatting
\begin{document}
   \begin{tikzpicture}
   ....
   \end{tikzpicture}
\end{document}

For example, memoir has somehow modified enumerate environment. If I use for exmple

\begin{enumerate}[1.]
\item some text
\end{enumerate}

gives error "item missing". Beside above example there are more cases of formatting which I like to use also in some pictures. How to do this since memoir can not be included as document style (package)?

5
  • 1
    that is the functionality from the enumerate package, I'd rather recommend using \usepackage[shortlabels]{enumitem} as it provides more features. Why do you need the standalone for the inclusion of figures when your main doc is memoir based?
    – daleif
    Commented Aug 8, 2014 at 7:06
  • I use standalone for inclusion of pictures. With standalone package I'm able to draw picture without to compile whole document. the second reason is probably even more important: with standalone i create set of pictures, which can anyone (read: my students) included as pdf files in their document (if they liked). On the another hand, I'm quit familiar with memoir and I'm not very keen to use additional package to the memoir, which functionality are already somehow incorporated in the memoir.
    – Zarko
    Commented Aug 8, 2014 at 8:10
  • 1
    Trust me you will want to learn enumitem, there are many things regarding lists that memoir does not provide interfaces to, enumitem do
    – daleif
    Commented Aug 8, 2014 at 8:22
  • I check packages enumitem and also enumerate. Indeed, the enumitem has nice capabilities for formatting of lists. The enumerate has number of preformatted lists, which are more close tho memoir combination \begin{enumerate}\firmlist, so I decide to mimic memoir lists in my tikz pictures with paralist. Thank you to give me idea, how I can mimic some meoir specific formating with other more specialized packages.
    – Zarko
    Commented Aug 8, 2014 at 12:13
  • 1
    In standalone class you need to use a minipage or tabular to handle more than one line of text. Commented Aug 10, 2014 at 17:05

1 Answer 1

2

The standalone class loads by default the article class internally, which can be changed using the class=<name> option.

If you want to put your enumerate environment inside a tikzpicture \node then you need also add the text width=<value> option so that the node can hold paragraph material. Otherwise you will get the same ! LaTeX Error: Something's wrong--perhaps a missing \item. as when class=memoir is missing!

\documentclass[12pt,tikz,class=memoir]{standalone}
\begin{document}
   \begin{tikzpicture}
    \node [text width=10em] at (0,0) {%
       \begin{enumerate}[1.]
            \item some text
            \item some text
        \end{enumerate}%
    };
   \end{tikzpicture}
\end{document} 
1
  • thank you very much for your answer. i hope that it will help to someone. i figured out this almost four years ago but in this time i wasn't aware that i can answer on my question :-(. anyway, +1 and i was accept it too.
    – Zarko
    Commented Dec 28, 2018 at 17:31

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .