]> git.lyx.org Git - lyx.git/blobdiff - src/TextClass.cpp
un-break display of toolbuttons wiuth delimiters
[lyx.git] / src / TextClass.cpp
index 8aae1abe87667f081ba339f8327cb8a461266ccc..eb71d7380b1bd950533f8feb2cedb682e949d671 100644 (file)
@@ -16,6 +16,7 @@
 
 #include "TextClass.h"
 #include "debug.h"
+#include "Layout.h"
 #include "Lexer.h"
 #include "Counters.h"
 #include "gettext.h"
 #include "support/os.h"
 
 #include <boost/filesystem/operations.hpp>
-namespace fs = boost::filesystem;
 
 #include <sstream>
 
+namespace fs = boost::filesystem;
 
 namespace lyx {
 
@@ -514,7 +515,7 @@ void TextClass::readTitleType(Lexer & lexrc)
                return;
        case TITLE_COMMAND_AFTER:
        case TITLE_ENVIRONMENT:
-               titletype_ = static_cast<LYX_TITLE_LATEX_TYPES>(le);
+               titletype_ = static_cast<TitleLatexType>(le);
                break;
        default:
                lyxerr << "Unhandled value " << le
@@ -619,6 +620,7 @@ enum InsetLayoutTags {
        IL_LATEXPARAM,
        IL_LATEXTYPE,
        IL_LYXTYPE,
+       IL_MULTIPAR,
        IL_PREAMBLE,
        IL_END
 };
@@ -637,6 +639,7 @@ void TextClass::readInsetLayout(Lexer & lexrc, docstring const & name)
                { "latexparam", IL_LATEXPARAM },
                { "latextype", IL_LATEXTYPE },
                { "lyxtype", IL_LYXTYPE },
+               { "multipar", IL_MULTIPAR },
                { "preamble", IL_PREAMBLE }
        };
 
@@ -648,10 +651,11 @@ void TextClass::readInsetLayout(Lexer & lexrc, docstring const & name)
        string decoration;
        string latexname;
        string latexparam;
-       Font font(Font::ALL_INHERIT);
-       Font labelfont(Font::ALL_INHERIT);
+       Font font(defaultfont());
+       Font labelfont(defaultfont());
        Color::color bgcolor(Color::background);
        string preamble;
+       bool multipar(false);
 
        bool getout = false;
        while (!getout && lexrc.isOK()) {
@@ -691,6 +695,10 @@ void TextClass::readInsetLayout(Lexer & lexrc, docstring const & name)
                        labelfont.lyxRead(lexrc);
                        labelfont.realize(defaultfont());
                        break;
+               case IL_MULTIPAR:
+                       lexrc.next();
+                       multipar = lexrc.getBool();
+                       break;
                case IL_FONT:
                        font.lyxRead(lexrc);
                        font.realize(defaultfont());
@@ -723,6 +731,7 @@ void TextClass::readInsetLayout(Lexer & lexrc, docstring const & name)
                il.latextype = latextype;
                il.latexname = latexname;
                il.latexparam = latexparam;
+               il.multipar = multipar;
                il.font = font;
                il.labelfont = labelfont;
                il.bgcolor = bgcolor;           
@@ -1168,7 +1177,7 @@ unsigned int TextClass::columns() const
 }
 
 
-LYX_TITLE_LATEX_TYPES TextClass::titletype() const
+TitleLatexType TextClass::titletype() const
 {
        return titletype_;
 }