[Tex/LaTex] Capitalize the first letter in acronym list

acronymscapitalization

When using the acronym package I would like to capitalize the first letter in the acronym description (e.g., Direct current). But when used in text I would like to have the word in lower letters.

\documentclass{article}
\usepackage{acronym}

\begin{document}
\begin{acronym}
\acro{DC}{direct current}
\end{acronym}

Batteries run on \ac{DC}.
\end{document}

Output:

DC direct current

Batteries run on direct current (DC).

Best Answer

You can patch the \AC@@acro macro that's responsible for printing the list of acronyms:

\documentclass{article}
\usepackage{acronym}
\usepackage{etoolbox}
\makeatletter
\patchcmd{\AC@@acro}{] #3}{] \MakeUppercase #3}{}{}
\patchcmd{\AC@@acro}{] #3}{] \MakeUppercase #3}{}{}
\makeatother

%%% Alternative way (commented out because you may not have the package)
% \usepackage{regexpatch}
% \makeatletter
% \xpatchcmd*{\AC@@acro}{] #3}{] \MakeUppercase #3}{}{}
% \makeatother

\begin{document}
\begin{acronym}
\acro{DC}{direct current}
\end{acronym}

Batteries run on \ac{DC}.
\end{document}

Update

With the most recent (2020) release of acronym things have changed (and may also change in the future). The right patch, current as of December 2020 is

\documentclass{article}
\usepackage{acronym}
\usepackage{etoolbox}
\makeatletter
\expandafter\patchcmd\csname AC@\AC@prefix{}@acro\endcsname{{#3}}{{\MakeUppercase #3}}{}{}
\expandafter\patchcmd\csname AC@\AC@prefix{}@acro\endcsname{{#3}}{{\MakeUppercase #3}}{}{}
\makeatother

\begin{document}
\begin{acronym}
\acro{DC}{direct current}
\end{acronym}

Batteries run on \ac{DC}.
\end{document}

enter image description here

Related Question