I wanted to know how to go about changing the algorithm caption label to blue and bold italics. I have so far been able to change the caption name to blue, but I have not been able to change the algorithm caption label to bold and italicized. Here is the code that I have so far:
\documentclass{article}
\usepackage{amsmath, amsfonts, amssymb, amsthm, bm}
\usepackage{commath}
\usepackage{xcolor}
\usepackage[linesnumbered,ruled,vlined]{algorithm2e}
\newcommand\mycommfont[1]{\footnotesize\ttfamily\textcolor{blue}{#1}}
\SetCommentSty{mycommfont}
\SetAlgoCaptionSeparator{.}
\renewcommand\AlCapFnt{\textit\textbf\color{blue}}
\usepackage[font={color=mybluei,bf,it},figurename=Fig.,labelfont={it}]{caption}
\begin{document}
\begin{center}
\colorbox[gray]{0.95}{
\begin{minipage}{0.65\textwidth}
\SetAlgoLined
\SetNlSty{textbf}{}{:}
\begin{algorithm}[H]
\DontPrintSemicolon
This is line one\\
This is line two numbered\\
This should be numbered\\
This should also be numbered
\caption{Unnumbered lines}
\end{algorithm}
\end{minipage}}
\end{center}
\end{document}
Best Answer
algorithm2e
's\caption
has the following format:Taken from the "change log":
With the above information, the following provides what you're after: