Again: sidecap figure

Paul A. Rubin parubin73 at gmail.com
Thu Mar 4 19:28:03 UTC 2021


On 3/4/21 3:39 AM, Wolfgang Engelmann wrote:
>
>
> Am 02.03.21 um 14:46 schrieb Wolfgang Engelmann:
>> In my preamble I have
>>
>> \usepackage{sidecap}
>> % Definition to put legends beside tables and figures
>> \newcommand{\TabBesBeg}[1][1.0]{%
>>   \let\MyTable\table
>>   \let\MyEndtable\endtable
>>   \renewenvironment{table}[1]{\begin{SCtable}[#1]##1}{\end{SCtable}}}
>>
>> \newcommand{\TabBesEnd}{%
>>   \let\table\MyTable
>>   \let\endtable\MyEndtable}
>>
>> \newcommand{\FigBesBeg}[1][1.0]{%
>>   \let\MyFigure\figure
>>   \let\MyEndfigure\endfigure
>>   \renewenvironment{figure}[1]{\begin{SCfigure}[#1]##1}{\end{SCfigure}}}
>>
>> \newcommand{\FigBesEnd}{%
>>   \let\figure\MyFigure
>>   \let\endfigure\MyEndfigure}
>>
>> In the document I use in ERT
>> \FigBesBeg} before the float figure and
>> \FigBesEnd} after the float figure
>>
>> but get this error:
>> ! Undefined control sequence.
>> l.279 ...lgae (see figure \ref{thalli}).\figBesBeg
>>
>> The control sequence at the end of the top line
>> of your error message was never \def'ed. If you have
>> misspelled it (e.g., `\hobx'), type `I' and the correct
>> spelling (e.g., `I\hbox'). Otherwise just continue,
>> and I'll forget about whatever was undefined.
>>
>> What is wrong?
>> Wolfgang
>
> I still struggle with sidecap figure and append a .tar.gz file with an 
> (almost) minimal example.
> The error I get:
>
> \figBesBeg
> The control sequence at the end of the top line
> of your error message was never \def'ed. If you have
> misspelled it (e.g., `\hobx'), type `I' and the correct
> spelling (e.g., `I\hbox'). Otherwise just continue,
> and I'll forget about whatever was undefined.
>
> I used the example in the LyX help file Embedded objects 3.10
> With my LyX et Co setup (Debian 11) I get with it
> ! Package babel Error: Unknown option `ngerman'. Either you misspelled it
> (babel)                or the language definition file ngerman.ldf was 
> not found.
> See the babel package documentation for explanation.
> Type  H <return>  for immediate help.
>
> But I can run it with 'show anyway' and the legend placement is 
> correctly sidewise.
>
> Could somebody be kind enough to run the example and see whether it 
> works in her/his case?
>
> My
> LyX Version 2.3.6
> (Friday, November 27, 2020)
> Library directory: /usr/share/lyx/
> User directory: ~/.lyx/
> Qt Version (run-time): 5.15.2
> Qt Version (compile-time): 5.15.1
>
> Wolfgang
>
The problem is that you defined \FigBesBegin and \FigBesEnd with capital 
"F" but invoked them with lowercase "f" (as in \figBesBegin). If you 
correct that, the document compiles.

Paul

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lyx.org/pipermail/lyx-users/attachments/20210304/bbfe543f/attachment.html>


More information about the lyx-users mailing list