]> git.lyx.org Git - features.git/commitdiff
tex2lyx/text.cpp: fix handling of \fbox
authorUwe Stöhr <uwestoehr@lyx.org>
Mon, 18 May 2015 21:45:27 +0000 (23:45 +0200)
committerUwe Stöhr <uwestoehr@lyx.org>
Mon, 18 May 2015 21:45:27 +0000 (23:45 +0200)
since a while now lyX supports inner boxes in \fbox, tex2lyx was outdated in this case

src/tex2lyx/test/box-color-size-space-align.tex
src/tex2lyx/text.cpp

index ccbf0cdad51f698e3d6abe9e0408ee7c8c02364c..28d40a16080356204122ff73f8af34da27a46365 100644 (file)
@@ -124,6 +124,10 @@ blabla \begin{framed}\begin{framed}nested framed\end{framed}\end{framed} blabla
 
 blabla \fbox{fbox} blabla
 
+\fbox{\begin{minipage}[t]{0.9\columnwidth}%
+fbox around minipage%
+\end{minipage}}
+
 blabla \framebox{fr\textcolor{blue}{ame}box 1} blabla
 
 blabla \framebox[3cm]{framebox 2} blabla
index 1178f3a01b27c686da06382aacf5df1714345d39..671c24e1c7edd2c4fbd4fdcba8f09c7d2e28c96a 100644 (file)
@@ -1127,7 +1127,7 @@ void parse_box(Parser & p, ostream & os, unsigned outer_flags,
                        os << "use_makebox 1\n";
                else
                        os << "use_makebox " << (inner_type == "makebox") << '\n';
-               if (outer_type == "fbox" || outer_type == "mbox")
+               if (outer_type == "mbox")
                        os << "width \"\"\n";
                // for values like "1.5\width" LyX uses "1.5in" as width ad sets "width" as sepecial
                else if (contains(width_unit, '\\'))
@@ -1260,8 +1260,7 @@ void parse_outer_box(Parser & p, ostream & os, unsigned flags, bool outer,
                        p.skip_spaces(true);
                }
        }
-       if (outer_type == "shaded" || outer_type == "fbox"
-               || outer_type == "mbox") {
+       if (outer_type == "shaded" || outer_type == "mbox") {
                // These boxes never have an inner box
                ;
        } else if (p.next_token().asInput() == "\\parbox") {