# How can I change the caption font and size for figures and tables

I want to specify the figure caption font size in order to follow a stupid standard at my university. I need the font to be Arial (I am using Helvetica because Arial is not available for LaTeX) 11pt. I have found:

\usepackage[font=md,labelfont=bf]{caption}


I have defined Heveltica as the default font for the whole document, so this constrain is hold. However, I cannot specify the font size. Is there another way to solve this issue?

• The fontsize for the document or for the captions? – user31729 Jul 30 '15 at 21:13
• 12pt. I have read that when the font size is 12pt, the font=small is 10.95pt, so I guess that solves my issue. Just waiting the one who is going to check that does not notice it. – lmiguelvargasf Jul 30 '15 at 21:22
• If you would do this in Germany, there would be definitely one at the office, taking a ruler and measure the height of your letters ;-) – user31729 Jul 30 '15 at 21:23
• The real size depends on the class however, for example the class options 12pt for book.cls will take the values from book12.clo – user31729 Jul 30 '15 at 21:25
• I'm from Ecuador, so here they won't use a ruler, but they would probably like to see some place where you have written the number 11. – lmiguelvargasf Jul 30 '15 at 21:25

You can use \DeclareCaptionFont and \fontsize{<size>}{<baselineskip>}\selectfont (\mdseries in the example below applies \selectfont):

\documentclass[12pt]{book}
\usepackage{caption}
\usepackage{mathptmx}
\usepackage[scaled=.90]{helvet}

\DeclareCaptionFont{xipt}{\fontsize{11}{13}\mdseries}
\usepackage[font=xipt,labelfont=bf]{caption}

\begin{document}

Regular text for comparison
\begin{table}
\caption{A test caption for a table}
\end{table}

\begin{figure}
\caption{A test caption for a figure}
\end{figure}

\end{document}


The result:

• What if I want the global font to be 12pt? I have notice that the solution you have provided solved my issue, but it emans that if I have set 12pt at the documentclass that is going to be the global font? – lmiguelvargasf Jul 30 '15 at 21:42
• @lmiguelvargasf I updated my answer with a global 12pt. No matter what the global font you select, \captionsetup will override this and give you the desired formatting for the captions. – Gonzalo Medina Jul 30 '15 at 21:44
• Why do I have to use scaled=0.9 for the package helvet? – lmiguelvargasf Jul 30 '15 at 21:44
• @lmiguelvargasf just to have the Helvetic family fonts match nicely with other families. I don't know exactly what fonts packages are you using, so it might be the case that you wouldn't need to scale the font. – Gonzalo Medina Jul 30 '15 at 21:46
• I guess that in my case it is not needed. The fonts that I am using are helvet instead of Arial and the other font is Times New Roman (\fontfamily{ptm}\fontseries{b}\fontsize{16}{10}\selectfont), but the last one is just for titles, subtitles (section and subsections). – lmiguelvargasf Jul 30 '15 at 21:50