Hallo,

there seems to be a bug in LyX version 2.1.3:
When importing a TeX file, LyX deletes the caption from \newtheorem.

For example, import the file below with:
     File -> Import -> LaTeX (plain)... -> test_import.tex
Then control the settings with:
     Document -> Settings... -> LaTeX Preamble
This gives:
     \newtheorem{theorem}{}[section]
That is, the second argument "{Theorem}" of \newtheorem has been replaced by "{}".

The import worked correctly under the version 2.0.6 which I had before.
(Operating system: Windows 8.1, 64 bit).

Yours,
Johannes Schmid

---------------- Example file test_import.tex -------------------------
%% LyX 2.1.3 created this file.  For more info, see http://www.lyx.org/.
%% Do not edit unless you really know what you are doing.
\documentclass[12pt,a4paper]{article}
\usepackage[latin9]{inputenc}

\makeatletter

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% LyX specific LaTeX commands.
\special{papersize=\the\paperwidth,\the\paperheight}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% User specified LaTeX commands.
\newtheorem{theorem}{Theorem}[section]

\makeatother

\begin{document}
This is only for test.
\end{document}
-------------------- End ----------------------------------------------

Reply via email to