mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-22 10:00:33 +00:00
Do not swallow math comments in tex2lyx.
This is not needed, since LyX supports comments in math. Data loss with math comments containing a backslash in LyX has been fixed as well. The test case was found in bug #8104.
This commit is contained in:
parent
4ce24954aa
commit
c9f68139cb
@ -1018,7 +1018,7 @@ bool Parser::parse1(InsetMathGrid & grid, unsigned flags,
|
||||
Token const & t = getToken();
|
||||
if (t.cat() == catNewline)
|
||||
break;
|
||||
s += t.asString();
|
||||
s += t.asInput();
|
||||
}
|
||||
cell->push_back(MathAtom(new InsetMathComment(buf, s)));
|
||||
skipSpaces();
|
||||
|
@ -121,7 +121,7 @@ void parse_math(Parser & p, ostream & os, unsigned flags, const mode_type mode)
|
||||
|
||||
else if (t.cat() == catComment) {
|
||||
if (!t.cs().empty())
|
||||
cerr << "Ignoring comment: " << t.asInput();
|
||||
os << t.asInput();
|
||||
else
|
||||
// "%\n" combination
|
||||
p.skip_spaces();
|
||||
|
@ -535,6 +535,15 @@ builtin \textasciicircum % with a comment
|
||||
A sub\textsubscript{sc\emph{ript}} and super\textsuperscript{script
|
||||
with $a^2+b^2=c^2$ math}.
|
||||
|
||||
\section{Mathematics\index{Mathematics}}
|
||||
|
||||
Let $f:\left[ a,b\right] \rightarrow%
|
||||
%TCIMACRO{\U{211d} }%
|
||||
%BeginExpansion
|
||||
\mathbb{R}
|
||||
%EndExpansion
|
||||
$.
|
||||
|
||||
\printindex{}
|
||||
|
||||
\printnomenclature hello
|
||||
|
Loading…
Reference in New Issue
Block a user