Eva
Eva

Reputation: 21

Figure (with caption) inside a longtable cell

I have a problem running on Latex. I have a huge longtable with an image inside each cell. Each image should have a counter and a caption. I have tried declaring the image as a figure (and it fails compiling) and also declaring it as minipage and using captionof, but as I could see searching through internet, captionof is uncompatible with longtable.

Is there a way to put an image (with its corresponding image counter and text) inside a longtable cell?

Upvotes: 1

Views: 1789

Answers (1)

Eva
Eva

Reputation: 21

Since \captionof was uncompatible with longtable, we need another way to:

  • set the proper counter,
  • set the appropiate type (figure or table, as you can use both),
  • set the proper title for the image.

For this purpose, I found this thread, and it worked almost perfectly. The only thing not mentioned in the thread is that you have to include the caption-text.sty NOT using \include{caption-text}, but \usepackage{caption-text}. For the rest, you can follow the instructions at the mentioned thread.

Upvotes: 1

Related Questions