]> git.lyx.org Git - lyx.git/blobdiff - src/insets/InsetLayout.cpp
Fix crash after undo following replacement of a multicell selection (#8973).
[lyx.git] / src / insets / InsetLayout.cpp
index c1a6c113c27b0445c7a5a2d206c709708a0473a8..6f1a02fdc1d0894f78843190f020a6994c14e5b7 100644 (file)
@@ -34,14 +34,14 @@ namespace lyx {
 InsetLayout::InsetLayout() :
        name_(from_ascii("undefined")), lyxtype_(STANDARD),
        labelstring_(from_ascii("UNDEFINED")), contentaslabel_(false),
-       decoration_(DEFAULT), latextype_(NOLATEXTYPE), font_(sane_font), 
+       decoration_(DEFAULT), latextype_(NOLATEXTYPE), font_(inherit_font), 
        labelfont_(sane_font), bgcolor_(Color_error), 
        htmlforcecss_ (false), htmlisblock_(true),
        multipar_(true), custompars_(true), forceplain_(false), 
        passthru_(false), parbreakisnewline_(false), freespacing_(false), 
        keepempty_(false), forceltr_(false), 
        needprotect_(false), intoc_(false), spellcheck_(true), 
-       resetsfont_(true), display_(true), forcelocalfontswitch_(false)
+       resetsfont_(false), display_(true), forcelocalfontswitch_(false)
 { 
        labelfont_.setColor(Color_error);
 }
@@ -551,6 +551,9 @@ void InsetLayout::readArgument(Lexer & lex)
                        arg.rdelim = lex.getDocString();
                        arg.rdelim = support::subst(arg.rdelim,
                                                    from_ascii("<br/>"), from_ascii("\n"));
+               } else if (tok == "defaultarg") {
+                       lex.next();
+                       arg.defaultarg = lex.getDocString();
                } else if (tok == "presetarg") {
                        lex.next();
                        arg.presetarg = lex.getDocString();