From 1a5891e1fd80e9272e195cc482724708f0ab96dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Uwe=20St=C3=B6hr?= Date: Mon, 5 Mar 2012 21:04:21 +0000 Subject: [PATCH] tex2lyx/text.cpp: don't parse catBegin in verbatim environments git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@40859 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/tex2lyx/Parser.cpp | 5 +---- src/tex2lyx/test/test-structure.tex | 2 +- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/src/tex2lyx/Parser.cpp b/src/tex2lyx/Parser.cpp index 75eb518203..06027e880a 100644 --- a/src/tex2lyx/Parser.cpp +++ b/src/tex2lyx/Parser.cpp @@ -488,10 +488,7 @@ string const Parser::plainEnvironment(string const & name) ostringstream os; for (Token t = get_token(); good(); t = get_token()) { - if (t.cat() == catBegin) { - putback(); - os << '{' << verbatim_item() << '}'; - } else if (t.asInput() == "\\end") { + if (t.asInput() == "\\end") { string const end = getArg('{', '}'); if (end == name) return os.str(); diff --git a/src/tex2lyx/test/test-structure.tex b/src/tex2lyx/test/test-structure.tex index b487bf17b4..71f4c423ec 100644 --- a/src/tex2lyx/test/test-structure.tex +++ b/src/tex2lyx/test/test-structure.tex @@ -296,7 +296,7 @@ jkh \ blah \begin{centering} -zzz +zzz \section{ \end{raggedleft} \end{verbatim}