0

For a conference submission I am using IEEEtran. I want to change the fontsize of caption for both figures and tables. By adding following code I am able to increase caption fontsize for tables but caption size of figures is not changing.

\usepackage{etoolbox}
\makeatletter
\patchcmd{\@makecaption}
{\footnotesize}{}{}{}
\patchcmd{\@makecaption}
{\footnotesize}{}{}{}
\patchcmd{\@makecaption}
{\footnotesize}{}{}{}
\patchcmd{\@makecaption}
{\footnotesize}{}{}{}
\makeatother
1
  • Part of the reason it is so hard to change IEEE captions is that IEEE doesn't want you to mess with them in any way. Commented Dec 12, 2022 at 20:27

1 Answer 1

1

Add the caption package and assign any font size to an optional setting font in its macro \captionsetup (see page 9 in documentation).

One thing though, IEEEtran already sets custom formatting for the floats and caption will override it; for instance, Fig. is supposed to be left aligned while caption will cause it centred. Therefore, some additional settings need to be used. Another thing is they have set specific font for floats for a reason. You may want to make sure they will accept custom changes.

\documentclass{IEEEtran}
\usepackage{blindtext}
\usepackage{graphicx}
\usepackage{caption}

\DeclareCaptionFormat{twolinetab}{#1#2\\#3}
\captionsetup{font=normalsize, skip=12pt}
\captionsetup[figure]{position=bottom, singlelinecheck=false}
\captionsetup[table]{format=twolinetab,position=top}

\title{The Title}


\begin{document}
\maketitle
\blindtext[1]

\begin{figure}[tbh]
  \centering
  \includegraphics[width=0.75\linewidth,height=3cm]{example-image}
  \caption{Example}
  \label{fig:example}
\end{figure}

\blindtext[2]

\begin{table}[tbh]
  \centering
  \caption{The Table}
  \begin{tabular}{l cc}
    Head & Val 1 & Val 2 \\
    \hline
    Row 1 & 1 & 2 \\
    Row 2 & 3 & 4
  \end{tabular}
\end{table}

\blindmathpaper\Blinddocument
\end{document}

enter image description here

You must log in to answer this question.

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