From: Uwe Stöhr Date: Wed, 20 May 2015 20:26:42 +0000 (+0200) Subject: tex2lyx/text.cpp: avoid a tex2lyx error message X-Git-Tag: 2.2.0alpha1~714 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=96874489f4c695a0e03e35d1d890e374bb739ebf;p=features.git tex2lyx/text.cpp: avoid a tex2lyx error message --- diff --git a/src/tex2lyx/text.cpp b/src/tex2lyx/text.cpp index 664e2925d5..ed2a3f7d9d 100644 --- a/src/tex2lyx/text.cpp +++ b/src/tex2lyx/text.cpp @@ -884,6 +884,7 @@ void parse_box(Parser & p, ostream & os, unsigned outer_flags, p.getArg('{', '}'); inner_type = "minipage"; inner_flags = FLAG_END; + active_environments.push_back("minipage"); } // parse parbox else if (p.next_token().asInput() == "\\parbox") { @@ -1237,6 +1238,8 @@ void parse_box(Parser & p, ostream & os, unsigned outer_flags, } #endif } + if (inner_type == "minipage" && (!frame_color.empty() || !background_color.empty())) + active_environments.pop_back(); if (inner_flags != FLAG_BRACE_LAST && (!frame_color.empty() || !background_color.empty())) { // in this case we have to eat the the closing brace of the color box p.get_token().asInput(); // the '}'