]> git.lyx.org Git - features.git/blobdiff - src/insets/InsetLayout.cpp
Provide option to force a local language switch where a global is not allowed (fixes...
[features.git] / src / insets / InsetLayout.cpp
index 1d7d1f0ee436ac3f9c41653f1ba557e449d5cb9a..9c9c7f2fce5ce5c726cdd4d252769955e80045f1 100644 (file)
@@ -41,7 +41,7 @@ InsetLayout::InsetLayout() :
        passthru_(false), parbreakisnewline_(false), freespacing_(false), 
        keepempty_(false), forceltr_(false), 
        needprotect_(false), intoc_(false), spellcheck_(true), 
-       resetsfont_(true), display_(true)
+       resetsfont_(true), display_(true), forcelocalfontswitch_(false)
 { 
        labelfont_.setColor(Color_error);
 }
@@ -87,6 +87,7 @@ bool InsetLayout::read(Lexer & lex, TextClass const & tclass)
                IL_DECORATION,
                IL_DISPLAY,
                IL_FONT,
+               IL_FORCE_LOCAL_FONT_SWITCH,
                IL_FORCELTR,
                IL_FORCEPLAIN,
                IL_FREESPACING,
@@ -135,6 +136,7 @@ bool InsetLayout::read(Lexer & lex, TextClass const & tclass)
                { "display", IL_DISPLAY },
                { "end", IL_END },
                { "font", IL_FONT },
+               { "forcelocalfontswitch", IL_FORCE_LOCAL_FONT_SWITCH },
                { "forceltr", IL_FORCELTR },
                { "forceplain", IL_FORCEPLAIN },
                { "freespacing", IL_FREESPACING },
@@ -236,6 +238,9 @@ bool InsetLayout::read(Lexer & lex, TextClass const & tclass)
                case IL_LEFTDELIM:
                        lex >> leftdelim_;
                        break;
+               case IL_FORCE_LOCAL_FONT_SWITCH:
+                       lex >> forcelocalfontswitch_;
+                       break;
                case IL_RIGHTDELIM:
                        lex >> rightdelim_;
                        break;