# Customize caption name of figures

I want to produce a figure caption like the following figure.

So I use the following package in the article environment.

\usepackage[format=plain,justification=raggedright,singlelinecheck=false,font=small,labelfont={bf,sf},labelsep=space,figurename=Figure]{caption}


However, what I get when I use \caption{\sffamily{\textbf{Quantum jumps}}} is

So, how do I get it to display Figure instead of Fig.? Also, how do I get the | next to Figure 1? When I set labelsep=|, I got an error.

Thanks.

Unless you're using a class that isn't compatible with caption, the following should work.

In order to define a | separator, use

\DeclareCaptionLabelSeparator{pipe}{ $|$ }% or $\vert$


\documentclass{article}

\usepackage{caption}
\DeclareCaptionLabelSeparator{pipe}{ $|$ }% or $\vert$
\captionsetup{
format=plain,
justification=raggedright,
singlelinecheck=false,
font=small,
font={bf,sf}, % This covers labelfont and textfont
labelsep=pipe,
figurename=Figure
}

\begin{document}

\begin{figure}
\caption{A caption}
\end{figure}

\end{document}

• Hi, I still got Fig. instead or Figure. Is it because I'm using two columns? How do I overcome this? Thanks. – user75521 Nov 3 '16 at 4:10
• @user75521: Nope. You must be loading some other package that is interfering. By the way, 8.5pt is not a document class option for article. – Werner Nov 3 '16 at 4:28