[Tex/LaTex] Combined list of tables and figures with separate numbering

floatstable of contents

I would like to have a list of figures and tables, together, as in this question, except that figures and tables should still have separate numbering systems. For instance, to end up with

List of Figures and Tables

  • Figure 1 : a picture
  • Table 1 : numbers
  • Figure 2 : another picture

How can this be done?

Best Answer

You can have figure information saved in the same place as the tables, and hence output at the same time, by adding the following lines in your preamble:

\makeatletter
\def\ext@figure{lot}
\makeatother

\renewcommand*\listtablename{List of Figures and Tables}

Here is a minimal working example:

\documentclass{article}

\makeatletter
\def\ext@figure{lot}
\makeatother

\renewcommand*\listtablename{List of Figures and Tables}

\begin{document}

\listoftables
\clearpage

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

\begin{table}
  \caption{Numbers}
\end{table}

\begin{figure}
  \caption{Another picture}
\end{figure}

\end{document} 

Output

enter image description here


If you want that list exactly as in your example, load the tocloft package and add the following lines in your preamble

\renewcommand{\cftfigpresnum}{Figure~}
\renewcommand{\cftfigaftersnum}{:}
\setlength{\cftfignumwidth}{5.5em}
\renewcommand{\cfttabpresnum}{Table~}
\renewcommand{\cfttabaftersnum}{:}
\setlength{\cfttabnumwidth}{5.5em}

MWE

\documentclass{article}

\usepackage{tocloft}

\makeatletter
\def\ext@figure{lot}
\makeatother

\renewcommand*\listtablename{List of Figures and Tables}

\renewcommand{\cftfigpresnum}{Figure~}
\renewcommand{\cftfigaftersnum}{:}
\setlength{\cftfignumwidth}{5.5em}
\renewcommand{\cfttabpresnum}{Table~}
\renewcommand{\cfttabaftersnum}{:}
\setlength{\cfttabnumwidth}{5.5em}

\begin{document}

\listoftables
\clearpage

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

\begin{table}
  \caption{Numbers}
\end{table}

\begin{figure}
  \caption{Another picture}
\end{figure}

\end{document} 

Output

enter image description here