Two questions:
Does LaTeX allow one to (re)define commands within a \newenvironment
? I've tried using \renewcommand
, \newcommand
and \def
in the before declaration but to no avail.
How would one redefine \item
when creating a new list environment?
I've created a new type of list environment from scratch using \newenvironment
while using another token instead of \item
for each but I'd really like to keep things consistent by using \list
and redefining \item
.
Too late perhaps, but it may be useful for someone else
\newenvironment{coolitemize}{%
\let\olditem\item%
\renewcommand\item[2][]{\olditem \textbf{##1}\\[0.3\baselineskip]##2}%
\begin{itemize}}{\end{itemize}%
}
and use it
\begin{coolitemize}
\item[Title of my first item] Text of my 1st item.
\item[Second one] And some text here.
\end{coolitemize}