]> git.lyx.org Git - lyx.git/blobdiff - src/lyxlayout.C
Collapse all those LFUN_XYZ_APPLY to a single LFUN_INSET_APPLY.
[lyx.git] / src / lyxlayout.C
index 0848e20bd6dd98f79f0075e63e521de23f78ae73..80e280b1577011124ebe46152a99a0d3602c5836 100644 (file)
 
 #include <config.h>
 
-#ifdef __GNUG__
-#pragma implementation
-#endif
-
 #include "lyxlayout.h"
 #include "lyxtextclass.h"
 #include "lyxlex.h"
@@ -121,7 +117,7 @@ bool LyXLayout::Read (LyXLex & lexrc, LyXTextClass const & tclass)
                { "alignpossible",      LT_ALIGNPOSSIBLE },
                { "bottomsep",          LT_BOTTOMSEP },
                { "copystyle",          LT_COPYSTYLE },
-               { "dependson",          LT_DEPENDSON },
+               { "dependson",          LT_DEPENDSON },
                { "end",                LT_END },
                { "endlabelstring",     LT_ENDLABELSTRING },
                { "endlabeltype",       LT_ENDLABELTYPE },
@@ -221,7 +217,7 @@ bool LyXLayout::Read (LyXLex & lexrc, LyXTextClass const & tclass)
                                        if (obsoleted_by().empty())
                                                obsoleted_by_ = style;
                                } else {
-                                       lyxerr << "Cannot replace with unknown style `" << style << "'" << endl;
+                                       lyxerr << "Cannot replace with unknown style `" << style << '\'' << endl;
 
                                        //lexrc.printError("Cannot replace with"
                                        //               " unknown style "
@@ -230,7 +226,7 @@ bool LyXLayout::Read (LyXLex & lexrc, LyXTextClass const & tclass)
                        }
                        break;
 
-               case LT_DEPENDSON: 
+               case LT_DEPENDSON:
                        if (lexrc.next()) {
                                depends_on_ = lexrc.getString();
                        }
@@ -249,10 +245,10 @@ bool LyXLayout::Read (LyXLex & lexrc, LyXTextClass const & tclass)
                        break;
 
                case LT_OPTARGS:
-                       if (lexrc.next()) { 
+                       if (lexrc.next()) {
                                optionalargs = lexrc.getInteger();
                        }
-                       break;
+                       break;
 
                case LT_NEED_PROTECT:
                        needprotect = lexrc.next() && lexrc.getInteger();
@@ -684,6 +680,7 @@ void LyXLayout::readMargin(LyXLex & lexrc)
 void LyXLayout::readLatexType(LyXLex & lexrc)
 {
        keyword_item latexTypeTags[] = {
+               { "bib_environment",  LATEX_BIB_ENVIRONMENT },
                { "command",          LATEX_COMMAND },
                { "environment",      LATEX_ENVIRONMENT },
                { "item_environment", LATEX_ITEM_ENVIRONMENT },
@@ -701,6 +698,7 @@ void LyXLayout::readLatexType(LyXLex & lexrc)
        case LATEX_COMMAND:
        case LATEX_ENVIRONMENT:
        case LATEX_ITEM_ENVIRONMENT:
+       case LATEX_BIB_ENVIRONMENT:
        case LATEX_LIST_ENVIRONMENT:
                latextype = static_cast<LYX_LATEX_TYPES>(le);
                break;