Re: [PATCH] bug 675: cannot insert a graphics in a caption
Jean-Marc == Jean-Marc Lasgouttes [EMAIL PROTECTED] writes: Jean-Marc As discussed in the bug, this fixes the bug by making Jean-Marc graphics in caption generate proper latex (with \protect). Jean-Marc It is then up to the user to realize that the graphics is Jean-Marc in the wrong place (note that there may be proper reason Jean-Marc for inserting a graphics in a caption). Jean-Marc I tested it and it works. Jean-Marc I will apply tomorrow if nobody complains. Applied. JMarc
Re: [PATCH] bug 675: cannot insert a graphics in a caption
> "Jean-Marc" == Jean-Marc Lasgouttes <[EMAIL PROTECTED]> writes: Jean-Marc> As discussed in the bug, this "fixes" the bug by making Jean-Marc> graphics in caption generate proper latex (with \protect). Jean-Marc> It is then up to the user to realize that the graphics is Jean-Marc> in the wrong place (note that there may be proper reason Jean-Marc> for inserting a graphics in a caption). Jean-Marc> I tested it and it works. Jean-Marc> I will apply tomorrow if nobody complains. Applied. JMarc
[PATCH] bug 675: cannot insert a graphics in a caption
http://bugzilla.lyx.org/show_bug.cgi?id=675 As discussed in the bug, this fixes the bug by making graphics in caption generate proper latex (with \protect). It is then up to the user to realize that the graphics is in the wrong place (note that there may be proper reason for inserting a graphics in a caption). I tested it and it works. I will apply tomorrow if nobody complains. JMarc Index: insetgraphics.C === --- insetgraphics.C (revision 13276) +++ insetgraphics.C (working copy) @@ -748,9 +748,15 @@ 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;
Re: [PATCH] bug 675: cannot insert a graphics in a caption
On Thu, Mar 23, 2006 at 03:24:55PM +0100, Jean-Marc Lasgouttes wrote: http://bugzilla.lyx.org/show_bug.cgi?id=675 As discussed in the bug, this fixes the bug by making graphics in caption generate proper latex (with \protect). It is then up to the user to realize that the graphics is in the wrong place (note that there may be proper reason for inserting a graphics in a caption). I tested it and it works. I will apply tomorrow if nobody complains. Great. Note that this will allow graphics in all layouts with NeedProtect = 1, also Part, Chapter and Section. - Martin pgpLEjo75JDUm.pgp Description: PGP signature
[PATCH] bug 675: cannot insert a graphics in a caption
http://bugzilla.lyx.org/show_bug.cgi?id=675 As discussed in the bug, this "fixes" the bug by making graphics in caption generate proper latex (with \protect). It is then up to the user to realize that the graphics is in the wrong place (note that there may be proper reason for inserting a graphics in a caption). I tested it and it works. I will apply tomorrow if nobody complains. JMarc Index: insetgraphics.C === --- insetgraphics.C (revision 13276) +++ insetgraphics.C (working copy) @@ -748,9 +748,15 @@ 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";
Re: [PATCH] bug 675: cannot insert a graphics in a caption
On Thu, Mar 23, 2006 at 03:24:55PM +0100, Jean-Marc Lasgouttes wrote: > > http://bugzilla.lyx.org/show_bug.cgi?id=675 > > As discussed in the bug, this "fixes" the bug by making graphics in > caption generate proper latex (with \protect). > > It is then up to the user to realize that the graphics is in the wrong > place (note that there may be proper reason for inserting a graphics > in a caption). > > I tested it and it works. > > I will apply tomorrow if nobody complains. Great. Note that this will allow graphics in all layouts with NeedProtect = 1, also Part, Chapter and Section. - Martin pgpLEjo75JDUm.pgp Description: PGP signature