[Tex/LaTex] Beamer-like description environment

beamerdescriptionlists

Where can I find the definition of the description environment available in beamer? I'd like to replicate it for my own needs in an article-oriented document. I'm interested in its right-left alignment features:

right-left alignment features

Best Answer

I recommend using the enumitem package which allows customizing list environments such as description. If you would edit your question specifying what's exactly desired, you could get an example.

The mdwlist package is an alternative focussing on description lists.

Here's a solution without these packages for right aligned description labels:

\documentclass{article}
\usepackage{calc}
\usepackage{xcolor}
\newcommand*{\desccolor}{blue}
\newcommand*{\widestlabel}{}
\newcommand*{\setwidestlabel}[1]{%
  \renewcommand*{\widestlabel}{#1}}
\renewcommand\descriptionlabel[1]{%
  \hspace\labelsep\parbox[t]{%
    \widthof{\widestlabel}}{\raggedleft\textcolor{\desccolor}{#1}}}
\begin{document}
\setwidestlabel{Second Item}
\begin{description}
\item[First Item] Description of first item
\item[Second Item] Description of second item
\item[Third Item] Description of third item
\item[Fourth Item] Description of fourth item
\end{description}
\end{document}

enter image description here

Related Question