2

My question

I'd like to create an extract of all my graphs in a separate document. How to extract all graphs used with \includegraphics in a document ?

Context

I used to use the extract package to automatically generate an external file with all the url of a Beamer presentation. However, extract package is not working well combined with beamer/beamerarticle unless you double information you want to extract by using \begin{extract} ... \end{extract} outside frames (as mentionned here).

I could probably work on directories to find directly use the images but the names are not consistent. My working folders look like

chap01
     image
          image1.png
          imagewithothername2.png
.
.
.
chap18
     image
          imagxx.png
          imayyyy.png

** Previous not great with beamerarticle solution**

\documentclass{beamer}
\usepackage{lipsum}
\usepackage[active,generate=images.tex,extract-cmd=section]{extract}
\begin{document}
\begin{frame}  
\begin{center}

\extractline \includegraphics[\textwidth]{example-image-a} \end{center} \end{frame}

\begin{frame}
\begin{center}
\extractline \includegraphics[\textwidth]{example-image-b} \end{center} \end{frame}

\begin{frame}
\lipsum \end{frame}

\begin{frame}
\begin{center}
\extractline \includegraphics[\textwidth]{example-image-c} \end{center} \end{frame}

\begin{frame}
\begin{center}
\extractline \includegraphics[\textwidth]{example-image-d} \end{center} \end{frame}

\end{document}

JeT
  • 3,020

0 Answers0