8

Is there any way of controlling the size of the subcaptions in a subfloat?

I've used:

\begin{figure}
\centering
\subfloat[Subcaption 1]{\label{fig:Pic_a} \includegraphics[width = 2.9cm]{Picture1}} \quad
\subfloat[Subcaption 2]{\label{fig:Pic_b} \includegraphics[width = 2.9cm]{Picture2}}
\end{figure}

So I've like to make the Subcaption1 and Subcaption2 smaller in textsize.

Thank you!

1
  • 1
    Welcome to TeX.SE! You can define caption fonts size and shapes with options when loading subfig or with \captionsetup[subfloat]{KV-list}. for details see package documentation.
    – Zarko
    Commented Jun 4, 2017 at 18:33

2 Answers 2

4

As given in table 3 of the subfig manual, use e.g.

\usepackage[
 font=footnotesize
 ]{subfig}

Alternatively, scriptsize or small. You can also set the font of the number and caption separately, with labelfont=... and/or textfont=....

\documentclass{article}
\usepackage[demo]{graphicx}
\usepackage[
 font=footnotesize % or small or scriptsize
 ]{subfig}
\begin{document}
\begin{figure}
\centering
\subfloat[Subcaption 1]{\label{fig:Pic_a} \includegraphics[width = 2.9cm]{Picture1}} \quad
\subfloat[Subcaption 2]{\label{fig:Pic_b} \includegraphics[width = 2.9cm]{Picture2}}
\end{figure}
\end{document}
0
2

It seems that the example code was not included, so here is one example code snippet.

\begin{figure}
    \centering
    \captionsetup[subfloat]{labelfont=scriptsize,textfont=scriptsize}
    \subfloat[Subcaption 1]{\label{fig:Pic_a} \includegraphics[width = 2.9cm]{figures/fig1}} \quad
    \subfloat[Subcaption 2]{\label{fig:Pic_b} \includegraphics[width = 2.9cm]{figures/fig2}}
\end{figure}

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .