<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<div class="moz-cite-prefix">On 3/4/21 3:39 AM, Wolfgang Engelmann
wrote:<br>
</div>
<blockquote type="cite"
cite="mid:96e3dc8c-3037-fbda-ff30-d82f05834b15@uni-tuebingen.de">
<br>
<br>
Am 02.03.21 um 14:46 schrieb Wolfgang Engelmann:
<br>
<blockquote type="cite">In my preamble I have
<br>
<br>
\usepackage{sidecap}
<br>
% Definition to put legends beside tables and figures
<br>
\newcommand{\TabBesBeg}[1][1.0]{%
<br>
\let\MyTable\table
<br>
\let\MyEndtable\endtable
<br>
\renewenvironment{table}[1]{\begin{SCtable}[#1]##1}{\end{SCtable}}}
<br>
<br>
\newcommand{\TabBesEnd}{%
<br>
\let\table\MyTable
<br>
\let\endtable\MyEndtable}
<br>
<br>
\newcommand{\FigBesBeg}[1][1.0]{%
<br>
\let\MyFigure\figure
<br>
\let\MyEndfigure\endfigure
<br>
\renewenvironment{figure}[1]{\begin{SCfigure}[#1]##1}{\end{SCfigure}}}
<br>
<br>
\newcommand{\FigBesEnd}{%
<br>
\let\figure\MyFigure
<br>
\let\endfigure\MyEndfigure}
<br>
<br>
In the document I use in ERT
<br>
\FigBesBeg} before the float figure and
<br>
\FigBesEnd} after the float figure
<br>
<br>
but get this error:
<br>
! Undefined control sequence.
<br>
l.279 ...lgae (see figure \ref{thalli}).\figBesBeg
<br>
<br>
The control sequence at the end of the top line
<br>
of your error message was never \def'ed. If you have
<br>
misspelled it (e.g., `\hobx'), type `I' and the correct
<br>
spelling (e.g., `I\hbox'). Otherwise just continue,
<br>
and I'll forget about whatever was undefined.
<br>
<br>
What is wrong?
<br>
Wolfgang
<br>
</blockquote>
<br>
I still struggle with sidecap figure and append a .tar.gz file
with an (almost) minimal example.
<br>
The error I get:
<br>
<br>
\figBesBeg
<br>
The control sequence at the end of the top line
<br>
of your error message was never \def'ed. If you have
<br>
misspelled it (e.g., `\hobx'), type `I' and the correct
<br>
spelling (e.g., `I\hbox'). Otherwise just continue,
<br>
and I'll forget about whatever was undefined.
<br>
<br>
I used the example in the LyX help file Embedded objects 3.10
<br>
With my LyX et Co setup (Debian 11) I get with it
<br>
! Package babel Error: Unknown option `ngerman'. Either you
misspelled it
<br>
(babel) or the language definition file ngerman.ldf
was not found.
<br>
See the babel package documentation for explanation.
<br>
Type H <return> for immediate help.
<br>
<br>
But I can run it with 'show anyway' and the legend placement is
correctly sidewise.
<br>
<br>
Could somebody be kind enough to run the example and see whether
it works in her/his case?
<br>
<br>
My
<br>
LyX Version 2.3.6
<br>
(Friday, November 27, 2020)
<br>
Library directory: /usr/share/lyx/
<br>
User directory: ~/.lyx/
<br>
Qt Version (run-time): 5.15.2
<br>
Qt Version (compile-time): 5.15.1
<br>
<br>
Wolfgang
<br>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
</blockquote>
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.<br>
<br>
Paul<br>
<br>
</body>
</html>