I'm trying to create a new command that will give blue underline under black text. My mwe is
\documentclass[a4paper,12pt]{report}
\usepackage[table,hyperref,dvipsnames]{xcolor}
\usepackage{ulem}
\newcommand{\coline}{\subsection{\textcolor{blue!80!black}\uline}}
\begin{document}
\coline{the cat sat on the mat}
\end{document}
but its failing saying
! Argument of \UL@on has an extra }.
<inserted text>
\par
l.11 \coline
{the cat sat on the mat}
?
I'm using xelatex to process it.
How can I get it working please?
I've just tried this, but its still not working.
\newcommand{\coline}{\textcolor{blue!80!black}\uline{\subsection}}




ulemfor coloring the underline or the check the definition of\reduline– percusse Mar 17 '15 at 19:35