[Tex/LaTex] Enumerated description list

#enumeratedescriptionlists

How can a list be created, whose items are both

  • enumerated (a,b,c,d,…)
  • and allow for setting a description via \item[texthere] ?

Im am using MikTex on Windows.

Best Answer

EDIT

Comment of Ben:

Could I also have a separate listclass, say enumdescript, such that I don't have to apply the settings manually everytime I want to use one of those lists?

The package enumitem provides a simple way to define you own list environments. The command \newlist in combination with setlist are the relavant commands. With \newlist you can define you own list and via \setlist set the settings. In the following example I define the environment enumdescript with the depth 2. Both commands are well explained in the documentation.

\documentclass{scrbook}

\usepackage{enumitem}
\newcounter{descriptcount}
\newlist{enumdescript}{description}{2}
\setlist[enumdescript,1]{%
  before={\setcounter{descriptcount}{0}%
          \renewcommand*\thedescriptcount{\alph{descriptcount}}}
  ,font=\bfseries\stepcounter{descriptcount}\thedescriptcount~
}
\setlist[enumdescript,2]{%
  before={\setcounter{descriptcount}{0}%
          \renewcommand*\thedescriptcount{\roman{descriptcount}}}
  ,font=\bfseries\stepcounter{descriptcount}\thedescriptcount~
}
\begin{document}

\begin{enumdescript}
   \item item one
   \item item two
   \item[Some Text] item three
   \begin{enumdescript}
      \item item one
      \item item two
      \item[Some Text] item three
   \end{enumdescript}
   \item item four
   \item item five
\end{enumdescript}
\end{document}

ORIGNIAL Answer:

Use the package enumitem in the newest version:

\documentclass{scrbook}

\usepackage{enumitem}
\newcounter{descriptcount}
\renewcommand*\thedescriptcount{\alph{descriptcount}}
\begin{document}

\begin{description}[%
  before={\setcounter{descriptcount}{0}},%
  ,font=\bfseries\stepcounter{descriptcount}\thedescriptcount~]
   \item item one
   \item item two
   \item[Some Text] item three
\end{description}

\end{document}

enter image description here