* insets/insetgraphics.C

(InsetGraphics::latex): add \protect as needed (bug 675)


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13478 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Jean-Marc Lasgouttes 2006-03-24 13:45:33 +00:00
parent e7141d6b86
commit 0a6cfff939

View File

@ -748,9 +748,15 @@ int InsetGraphics::latex(Buffer const & buf, ostream & os,
string after;
// Do we want subcaptions?
if (params().subcaption) {
if (runparams.moving_arg)
before += "\\protect";
before += "\\subfigure[" + params().subcaptionText + "]{";
after = '}';
}
if (runparams.moving_arg)
before += "\\protect";
// We never use the starred form, we use the "clip" option instead.
before += "\\includegraphics";