In IEEE ACCESS template latex file, there is a example code of "\Figure", when inserting pictures into paper.
But I want to use figure and subfigure environment to fit my requirement. So I add usepackage of "subfigure" and "caption", except for losing figure's caption color it works well. If I cancel the usagepackage of "caption", compiler error occurs: "Undefined control sequence. \caption{Universe}"
How I can use figure and subfigure which shows correctly and normally(with color caption) in my paper? (I am using MikTex and Texstudio in Windows10)
Following is the source code of latex file and error picture.
IEEE ACCESS template is here.
latex source code:
% !TeX spellcheck = en_US
\documentclass{ieeeaccess}
\usepackage{cite}
\usepackage{amsmath,amssymb,amsfonts}
\usepackage{algorithm}
\usepackage{algorithmic}
\usepackage{graphicx}
\usepackage{subfigure} % support sub-figure
% compiler error without following two lines
%\usepackage{caption,setspace}
%\captionsetup{font={small,stretch=0.80}}
\usepackage{textcomp}
\def\BibTeX{{\rm B\kern-.05em{\sc i\kern-.025em b}\kern-.08em
T\kern-.1667em\lower.7ex\hbox{E}\kern-.125emX}}
\begin{document}
\begin{abstract}
hese instructions give you guidelines for preparing papers for
IEEE Access. Use this document as a template if you are
using \LaTeX. Otherwise, use this document as an
instruction set.
\end{abstract}
\begin{keywords}
Figure, Float, SubFigure
\end{keywords}
\titlepgskip=-15pt
\section{Introduction}
\label{sec:introduction}
\PARstart{T}{his} document is a template for \LaTeX. If you are
reading a paper or PDF version of this document, please download the
electronic file \ref{fig:universe}.
\begin{figure}[h!]
\centering
\includegraphics[scale=1.0]{universe.jpg}
\caption{Universe}
\label{fig:universe}
\end{figure}
\EOD
\end{document}
Best Answer
If you are allowed to change the template, you can use the
labelfont
key in\captionsetup
to set the color. Finding the latter took some digging in the code of the class. I also took the freedom to set the fonts according to the template (sf
andbf
).The code: