[Tex/LaTex] Naming enumerated lists referencing the names

#enumeratecross-referencinglists

Currently I have the following TeX

\begin{enumerate}
\item First idea
\item \label{idea:s} Second idea
\end{enumerate}

\begin{enumerate}
\item Point about \ref{idea:s}
\end{enumerate}

I would like to be able to somehow name the lists themselves, and then the reference idea:s could be something like List I.a, or something like that. How can I name enumerated lists? I was thinking that defining an environment like a theorem environment would work, but is there a more preferred way?

http://en.wikibooks.org/wiki/LaTeX/Theorems#Basic_theorems

Best Answer

This might be what you're after, and uses the enumitem package to obtain the appropriate formatting.

A new environment biglist is created that has the following default formatting:

  • Item labels are given as a Roman numeral indicating the list identifier/name, followed by ., followed by the item number (in alphabetic enumeration).
  • Item references are given as List~<label> where <label> is as described above.

This will allow you to use the enumerate environment for other lists in your document, while biglist is reserved for your "named lists". The formatting, of course (in terms of labelling and referencing) can be modified. Additional options can also be specified via an optional argument to \begin{biglist}[<other parameters>]. These include the item separation, indent, etc.

enter image description here

\documentclass{article}
\usepackage{enumitem}% http://ctan.org/pkg/enumitem
\newcounter{biglist} \renewcommand{\thebiglist}{\Roman{biglist}}%
\newenvironment{biglist}[1][*]
  {\stepcounter{biglist}%
   \begin{enumerate}[label=\thebiglist.\alph*,ref=List~\thebiglist.\alph*,#1]}% \begin{biglist}
  {\end{enumerate}}% \end{biglist}
\begin{document}
\begin{biglist}
\item First idea
\item \label{idea:s} Second idea
\end{biglist}

\begin{enumerate}
\item Point about \ref{idea:s}
\end{enumerate}
\end{document}​

The above can be made more dynamic by allowing you to specify the name as an optional argument as well, and even choose between something other than (say) List, or stick to that as the default.

Related Question