]> git.lyx.org Git - lyx.git/blobdiff - src/paragraph.C
partial fix for cut and paste
[lyx.git] / src / paragraph.C
index c421f567406faf0a3c36640aad45021d8de88b90..5a7131ab3cc6e8f4553aba5def966d9690410ba7 100644 (file)
@@ -306,7 +306,7 @@ void Paragraph::insertInset(pos_type pos, InsetBase * inset,
 
 bool Paragraph::insetAllowed(InsetOld_code code)
 {
-       return pimpl_->inset_owner->insetAllowed(code);
+       return !pimpl_->inset_owner || pimpl_->inset_owner->insetAllowed(code);
 }
 
 
@@ -1570,8 +1570,7 @@ bool Paragraph::isMultiLingual(BufferParams const & bparams) const
 
 // Convert the paragraph to a string.
 // Used for building the table of contents
-string const Paragraph::asString(Buffer const & buffer,
-                                bool label) const
+string const Paragraph::asString(Buffer const & buffer, bool label) const
 {
        OutputParams runparams;
        return asString(buffer, runparams, label);