Skip to content

Commit 41e7143

Browse files
author
Dimitri van Heesch
committed
Merge pull request doxygen#441 from albert-github/feature/bug_image_in_table
PDF generation stops when image with caption is included in a table.
2 parents 4d91798 + 1d77a4e commit 41e7143

File tree

3 files changed

+15
-1
lines changed

3 files changed

+15
-1
lines changed

doc/manual.sty

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,3 +31,10 @@
3131
\fancyfoot[CO]{\fancyplain{}{}}
3232
\fancyfoot[RO]{\fancyplain{}{}}
3333

34+
% Define caption that is also suitable in a table
35+
\makeatletter
36+
\def\doxyfigcaption{%
37+
\refstepcounter{figure}%
38+
\@dblarg{\@caption{figure}}}
39+
\makeatother
40+

src/latexdocvisitor.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ static void visitPreStart(FTextStream &t, const bool hasCaption, QCString name,
114114

115115
if (hasCaption)
116116
{
117-
t << "\n\\caption{";
117+
t << "\n\\doxyfigcaption{";
118118
}
119119
}
120120

templates/latex/doxygen.sty

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -475,3 +475,10 @@
475475

476476
% Color used for table heading
477477
\newcommand{\tableheadbgcolor}{lightgray}%
478+
479+
% Define caption that is also suitable in a table
480+
\makeatletter
481+
\def\doxyfigcaption{%
482+
\refstepcounter{figure}%
483+
\@dblarg{\@caption{figure}}}
484+
\makeatother

0 commit comments

Comments
 (0)