# Change separator between caption label and number

I've tried to accomplish this for some time with the caption package, but with no result. What I want to do is change the following:

Figure 1: text

into

Figure-1: text

I.e. replace the space with a dash.

-
Is the "dash" symbol supposed to be a "simple" dash, i.e., a hyphen character, or an "en-dash"? –  Mico Jun 13 '12 at 15:29

You find it in section 4 of the manual: you have to define a new label format style. I added only the relevant setup, you can set the other keys as usual.

\documentclass{article}

\usepackage{graphicx}
\usepackage{caption}
\DeclareCaptionLabelFormat{dash}{#1--#2}
\captionsetup[figure]{labelformat=dash}

\begin{document}
\begin{figure}
\centering
\includegraphics[width=5cm]{example-figure-a}
\caption{abc}
\end{figure}
\end{document}


-